Click here to Skip to main content
15,905,607 members

Comments by Stefano Lodico (Top 6 by date)

Stefano Lodico 1-Nov-15 13:40pm View    
The question is: What's the problem with this code? I tried with gdb and it tell me "Inferior 1". It stop to the first step. Why this problems? Where is the error in this code?
Stefano Lodico 31-Oct-15 13:07pm View    
I updated the main post.
Stefano Lodico 31-Oct-15 13:07pm View    
I updated the main post.
Stefano Lodico 31-Oct-15 9:32am View    
Sorry
Stefano Lodico 31-Oct-15 9:16am View    
This is compiler result:

m.cpp: In member function ‘T matrix::crea()’:
m.cpp:17:15: error: expected type-specifier before ‘<’ token
auto a = new<t>*(riga);
^
m.cpp:17:17: error: expected primary-expression before ‘>’ token
auto a = new<t>*(riga);
^
m.cpp:17:24: error: invalid type argument of unary ‘*’ (have ‘int’)
auto a = new<t>*(riga);
^
m.cpp:20:12: error: expected type-specifier before ‘<’ token
a[i]=new<t>(colonna);
^
m.cpp:20:14: error: expected primary-expression before ‘>’ token
a[i]=new<t>(colonna);
^
m.cpp: In function ‘int main()’:
m.cpp:31:9: error: ‘crea’ was not declared in this scope
auto v=crea<int>(5,10);
^
m.cpp:31:14: error: expected primary-expression before ‘int’
auto v=crea<int>(5,10);