mescc: Bugfix for merging objects.

* mlibc/libc-mes.c (main): Declare.
* mlibc/mini-libc-mes.c (g_stdin): Define.
  (main): Declare.
* module/language/c99/compiler.mes (alist-add): Thinko.  Fixes merging
  objects when first declares function of next.
This commit is contained in:
Jan Nieuwenhuizen 2017-06-04 22:44:21 +02:00
parent 5267247991
commit 86b891ecb6
3 changed files with 6 additions and 2 deletions

View file

@ -360,6 +360,7 @@ _env (char **e)
return e;
}
int main(int,char*[]);
int
_start ()
{

View file

@ -18,6 +18,8 @@
* along with Mes. If not, see <http://www.gnu.org/licenses/>.
*/
int g_stdin = 0;
void
exit ()
{
@ -60,6 +62,7 @@ _env (char **e)
return e;
}
int main(int,char*[]);
int
_start ()
{

View file

@ -2452,6 +2452,6 @@
(define (alist-add a b)
(let* ((b-keys (map car b))
(a (filter (lambda (f) (or (cdr f) (not (member f b-keys)))) a))
(a (filter (lambda (f) (or (cdr f) (not (member (car f) b-keys)))) a))
(a-keys (map car a)))
(append a (filter (lambda (e) (not (member (car e) a-keys))) b))))