Mercurial > archived > louis > epitech > mq > rathaxes
view wip_debug.patch @ 127:72b5b4a62cc5
Wip on fixing ref/scalar issues, partly fixed
author | Louis Opter <louis@lse.epita.fr> |
---|---|
date | Sun, 18 Aug 2013 15:33:24 -0700 |
parents | |
children | 0fdaa93ed62b |
line wrap: on
line source
# HG changeset patch # Parent ea807d6831821c5fb094e7ae9258f5a282ec15e6 diff --git a/rathaxes/compiler/passes/common/rtxResolve.inc.cws b/rathaxes/compiler/passes/common/rtxResolve.inc.cws --- a/rathaxes/compiler/passes/common/rtxResolve.inc.cws +++ b/rathaxes/compiler/passes/common/rtxResolve.inc.cws @@ -782,6 +782,11 @@ return false; } + if (coreString(local_node#parent.location,0,2) == "/home/kal/projs/rathaxes/rathaxes/samples/e1000/e1000.blt:971:") + { + traceLine(BLUE + toString(mapping,true) + DEFAULT_COLOR); + } + if (isString(mapping)) { local_node#parent.ref_placeholder.id = mapping; @@ -812,9 +817,18 @@ } local in_type = source_type.qualifier; local out_type = local_node#parent.ph_type; + traceLine("paf: " + local_node#parent.location); + if (local_node#parent.location == "/home/kal/projs/rathaxes/rathaxes/samples/e1000/ethernet.blt:124:40") + { + traceLine(YELLOW + "in_type = " + in_type+ DEFAULT_COLOR); + traceLine(YELLOW + "out_type = " + out_type+ DEFAULT_COLOR); + traceLine(CYAN + toString(resolverValues,true) + DEFAULT_COLOR); + } if (rtxResolve_RefScalarTranscribe(mapping, in_type, out_type) == false) { error(RED + "[Error] Cannot transcribe an expression from " + in_type + " to " + out_type + DEFAULT_COLOR); } setall local_node#parent.ref_placeholder = mapping; + if (coreString(local_node#parent.location,0,2) == "/home/kal/projs/rathaxes/rathaxes/samples/e1000/e1000.blt:971:") + exit(1); } } else if (isBuiltinVariable(varName)) // Mapping for a builtin type @@ -1445,6 +1459,12 @@ } rtxNodeArg_getValue(self, val); setall out_node = val; + if (placeHolder#parent.location == "/home/kal/projs/rathaxes/rathaxes/samples/e1000/ethernet.blt:124:40") + { + traceLine(PURPLE + toString(val,true)+ DEFAULT_COLOR); + //error("toto"); + //exit(1); + } } return true;