IRC channel logs

2024-02-26.log

back to list of logs

<vagrantc>/30/30
<webczat>hi, when I try to compile make i get mescc errors like "ast->type: not supported" without any other indication. what do they mean?
<webczat>the file really doesn't look like it contained anything special, but idk
<webczat>would be nice to learn how to actually debug problems.
<ekaitz>webczat: error or warning?
<ekaitz>webczat: what file are you building?
<webczat>error
<webczat>building the...
<webczat>concat-filename.c in make
<webczat>building it with mescc directly
<ekaitz>webczat: hmm
<ekaitz>probably something unsupported
<webczat>ekaitz: okay. but what? where? how to check that?
<webczat>that's the problem. i have not enough info or anything to even try to debug that
<ekaitz>yeah i know
<webczat>also this file really doesn't look like containing anything unsupported
<ekaitz>do you have a link to that file?
<ekaitz>so i can read it
<webczat>ekaitz: i might probablyy transport it o ut of that environment. unless i fifind it inn the souurce control
<ekaitz>i have make a checkout but i didn't find that file
<webczat>ekaitz: it seems like it's either generated or copied to the destination place either during autoreconf or configure
<ekaitz>can you paste it in a pastebin or something?
<webczat>ekaitz: yes, but i need to transport it out first, sec
<ekaitz>the error message you get contains some line information or it's just that?
<webczat>ekaitz: i have never seen accurate line info coming from mescc tbh
<webczat> https://paste.mod.gg/ioojmeemvdhz/0
<webczat>no headers included. there are some light macro usages there so\
<webczat>btw it might lack some lines because it is a copy i made to check if after I remove some of them it magically starts working, to try to isolate the error.
<webczat>forgot about it. but nothing changed
<webczat>btw, when i run mescc with the -v switch it shows the function name before the error.
<ekaitz>oh this is not that large
<ekaitz>pretty weird
<ekaitz>i was expecting something more obvious
<webczat>ekaitz: no. that's why I was surprised because it's very small and very... hmm usuall I'd say
<ekaitz>but I don't see where it can be failing
<webczat>me too
<webczat>the problem is i have the impression any and all files are failing that way. considering it can compile the mes and things like bootstrappable tcc, this code is something really trivial
<ekaitz>yep
<ekaitz>it's probably something stupid we didn't think about
<ekaitz>did you try with mescc that uses guile? i think that has better error reporting
<webczat>ekaitz: i am in a bootstrap environment. i don't have enough support to build make, so also not guile :)
<webczat>although might it be bugs in mes that would disappear when rebuilding mes with mescc? although i am pretty sure the mes is built with mescc as a part of normal bootstrap
<ekaitz>yes it is
<ekaitz>maybe it's some of those macro expansions in the file?
<webczat>maybe, but ... i removed calls to stpcpy which is probably one of them. and other ones are kinda trivial I think. unless mescc preprocessor has problems with parameterized macros, although not sure if any of them is even used
<ekaitz>hmmm
<ekaitz>idk mate
<ekaitz>you can try to expand it first?
<webczat>ekaitz: hmm passing it through preprocessor? mb
<ekaitz>yes
<webczat>might be a good idea. i get a similar but a bit different error when I am missing headers. it errors out about headers, then gives an error about "expr->register: not supported" which is a bit different than the one I get, but
<webczat>these errors really say nothing. or maybe they do? can you tell me what these errors mean, in theory?
<webczat>also this is a bit older mes. although the same/similar was happening with newest one
<webczat>hmm after passing this through preprocessor I really don't recognize wtf is the output.
<webczat>it became kinda unreadable. it's definitely not looking like a normal preproc result
<ekaitz>the error expr->register means it's trying to compile an expression and it's not able to do it
<ekaitz>maybe because the expression is not implemented
<ekaitz>or because it's interpreting something as an expression where it shouldn't
<ekaitz>it's hard to know
<webczat>what about as->type?
<webczat>ekaitz: i am pretty sure you could make nicer error messages :P although unsure, haven't written any parser in my lifetime. although this seems to happen after actual parsing
<webczat>*ast->type
<ekaitz>haha
<ekaitz>they can be improved, for sure
<ekaitz>ast->type is trying to obtain the type of an expression i think
<ekaitz>but i'm not sure
<ekaitz>ACTION has to go
<webczat>okay