Removed the C++ code for IsChannelArray, so that the C version is used instead
This commit is contained in:
parent
4c0c27f350
commit
a583403372
|
@ -927,16 +927,6 @@ cppintroduceSpec ops (A.Specification _ n (A.IsExpr _ am t e))
|
||||||
rhs
|
rhs
|
||||||
tell [";\n"]
|
tell [";\n"]
|
||||||
|
|
||||||
-- We must create the channel array then fill it:
|
|
||||||
cppintroduceSpec ops (A.Specification _ n (A.IsChannelArray _ t cs))
|
|
||||||
= do call genDeclaration ops t n False
|
|
||||||
sequence_ $ map genChanArrayElemInit (zip [0 .. ((length cs) - 1)] cs)
|
|
||||||
where
|
|
||||||
genChanArrayElemInit (index,var)
|
|
||||||
= do genName n
|
|
||||||
tell ["[",show index,"].access() = "] --Use the .access() function to cast a 0-dimension array into a T& for access
|
|
||||||
call genVariable ops var
|
|
||||||
tell [";"]
|
|
||||||
--This clause was simplified, because we don't need separate array sizes in C++:
|
--This clause was simplified, because we don't need separate array sizes in C++:
|
||||||
cppintroduceSpec ops (A.Specification _ n (A.RecordType _ b fs))
|
cppintroduceSpec ops (A.Specification _ n (A.RecordType _ b fs))
|
||||||
= do tell ["typedef struct{"]
|
= do tell ["typedef struct{"]
|
||||||
|
|
Loading…
Reference in New Issue
Block a user