kfl / mosml

Moscow ML is a light-weight implementation of Standard ML (SML), a strict functional language widely used in teaching and research.
http://mosml.org
341 stars 42 forks source link

mmysql.c fails to compile #68

Open cwfoo opened 3 years ago

cwfoo commented 3 years ago

Compiling mmysql.c using mmysql's Makefile fails with this error:

mmysql.c: In function ‘dbresult_finalize’:
mmysql.c:79:28: error: lvalue required as left operand of assignment
     DBresult_val(dbresval) = NULL;
                            ^
mmysql.c:81:33: error: lvalue required as left operand of assignment
     DBresultindex_val(dbresval) = NULL;
                                 ^

This is the function in question: https://github.com/kfl/mosml/blob/ee355b296f393a8a0bf9de9e8dbe8a5915c92ed6/src/dynlibs/mmysql/mmysql.c#L73-L83

mosml version: 2.10.1 libmysqlclient version: 5.7.21 Compiler: gcc 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04) OS: Ubuntu 18.04.2