(forgot to incude: Mac OS X 10.11.4

$ util/printchplenv
machine info: Darwin hodor.local 15.4.0 Darwin Kernel Version 15.4.0: Fri
Feb 26 22:08:05 PST 2016; root:xnu-3248.40.184~3/RELEASE_X86_64 x86_64
CHPL_HOME: /Users/swenson/chapel *
script location: /Users/swenson/chapel/util
CHPL_TARGET_PLATFORM: darwin
CHPL_TARGET_COMPILER: clang
CHPL_TARGET_ARCH: native
CHPL_LOCALE_MODEL: flat
CHPL_COMM: none
CHPL_TASKS: qthreads
CHPL_LAUNCHER: none
CHPL_TIMERS: generic
CHPL_MEM: jemalloc
CHPL_MAKE: make
CHPL_ATOMICS: intrinsics
CHPL_GMP: gmp
CHPL_HWLOC: hwloc
CHPL_REGEXP: re2
CHPL_WIDE_POINTERS: struct
CHPL_AUX_FILESYS: none


$ clang++ --version
Apple LLVM version 7.3.0 (clang-703.0.29)
Target: x86_64-apple-darwin15.4.0
Thread model: posix
InstalledDir:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin

)

--Christopher



On Mon, Mar 28, 2016 at 2:51 PM, Christopher Swenson <[email protected]>
wrote:

> I ran into an internal error.
>
> Minimal reproducer is
>
> proc f() : (int, int) {
>   return f();
> }
> proc main() {
>   f();
> }
>
> output:
> repro.chpl:2: internal error: number of actuals does not match number of
> formals [callDestructors.cpp:1120]
>
> (Also at https://gist.github.com/swenson/34490cd907cc8330614e)
>
>
> I did some debugging, and the function where the asserting is reads:
>
> ...
> void insertReferenceTemps(CallExpr* call) {
>   for_formals_actuals(formal, actual, call)
> ...
>
> It appears as though the tuple is created to contain the return value, and
> when the destructor is invoked, it has to pass the implicit self (_ref),
> which is what I think insertReferenceTemps is doing. However,
> for_formals_actuals only works if the implicit self has already been
> inserted?
>
> I have a workaround that patches for_formals_actuals, but I'd be afraid it
> introduces more bugs than it cures, so I'm trying to figure out why this is
> only occurring here, and not for every destructor call. Any pointers would
> be appreciated. :)
>
> --Christopher
>
>
------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785471&iu=/4140
_______________________________________________
Chapel-bugs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/chapel-bugs

Reply via email to