[Issue 6559] [CTFE-ish] Inconsistent array formatting at runtime vs compiletime
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Aug 29 00:51:39 PDT 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6559
Don <clugdbug at yahoo.com.au> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |clugdbug at yahoo.com.au
--- Comment #1 from Don <clugdbug at yahoo.com.au> 2011-08-29 00:51:37 PDT ---
(In reply to comment #0)
> > type testArrayOut.d
> import std.stdio;
> immutable arr = [ 1 , 2 , 3 ];
> void main()
> {
> pragma(msg, arr);
> writeln(arr);
> }
>
> > dmd testArrayOut.d
> [1,2,3]
>
> > testArrayOut
> [1, 2, 3]
>
> The formatting should be the same at both runtime and compile-time.
You're assuming that pragma(msg) and writeln use the same format, but I'm not
sure why. AFAIK there is nothing in the spec that should give that impression.
They are completely unrelated features.
pragma(msg) uses the same format that is used for error messages.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list