[Issue 8884] New: std.array RefAppender do not works with .ptr
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Oct 24 05:32:27 PDT 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8884
Summary: std.array RefAppender do not works with .ptr
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
Component: Phobos
AssignedTo: nobody at puremagic.com
ReportedBy: bioinfornatics at gmail.com
--- Comment #0 from bioinfornatics <bioinfornatics at gmail.com> 2012-10-24 05:32:25 PDT ---
it seem RefAppender do not works with .ptr array property
_____________________________________
This code give: [0, 1, 2, 3, 4, 5, 6, 7]
-----------------------
import std.stdio;
import std.array;
void main(){
size_t[] a =[ 0,1,2,3 ];
auto a2 = appender( &a );
a2.put( [4, 5, 6, 7 ] );
writeln( a );
}
_____________________________________
This code give:
Error: template std.array.appender does not match any function template
declaration
Error: template std.array.appender cannot deduce template function from
argument types !()(ulong*)
-----------------------
import std.stdio;
import std.array;
void main(){
size_t[] a =[ 0,1,2,3 ];
auto a2 = appender( a.ptr );
a2.put( [4, 5, 6, 7 ] );
writeln( a );
}
--
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