jckarter / clay Goto Github PK
View Code? Open in Web Editor NEWThe Clay programming language
Home Page: http://claylabs.com/clay
License: Other
The Clay programming language
Home Page: http://claylabs.com/clay
License: Other
Providing staticIndex
for record types causes confusing things like vector.0
to work, when they really shouldn't.
Failed tests:
commandline\dispatch
externals\abi
floats\literals\long
io\sockets\addresses
io\sockets\connections
io\sockets\reading
io\sockets\valuesemantics
lua\capi\claytolua
lua\capi\luahello
lua\capi\luatoclay
lua\highlevel\claytolua
lua\highlevel\customtype1
lua\highlevel\customtype2
lua\highlevel\customtype3
lua\highlevel\customtype4
lua\highlevel\customtype5
lua\highlevel\luahello
lua\highlevel\luatoclay
math\1
numbers\parser\1
numbers\parser\4
parsing
printing\int128
remote\messages\simple
sqlite
sqlite\sequences
uncategorized\41
uncategorized\7
=====================
commandline\dispatch
=====================
compiler error
--------------
clayobj.obj-694158 : error LNK2019: unresolved external symbol _strtoll referenced in function _clay_printlnUsage_28_StringConstant_2C__20_StringConstant_2C__20_Vector_5B_Char_5D__2C__20_StringConstant_2C__20_StringConstant_29_
test.exe : fatal error LNK1120: 1 unresolved externals
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
externals\abi
=====================
out.txt and err.txt mismatch
expected out.txt
----------------
Passing C arguments to Clay:
3248800164u, true, 0x1.c1a4c0p+123f, 0x1.c1a4c1a4c1a4cp+123
0x1.c1a4c0p+123f+0x1.abcdeep+99fj
0x1.c1a4c1a4c1a4cp+123+0x1.abcdefabcdefap+99j
Struct1(13953490458868236708ul)
Struct2(3248800164u)
Struct3(3248800164u, 305419896u)
Struct4(3248800164u, 305419896u, 2882382797u)
Struct5(3248800164u, 305419896u, 12379739850550389709ul)
Struct6(3248800164u, 12379739850550389709ul)
Struct7(3248800164u, 12379739850550389709ul, 305419896u)
Struct8(13953490458868236708ul, 12379739850550389709ul, 1311768465173141112ul)
Struct9(3248800164u, 0x1.c1a4c1a4c1a4cp+123)
Struct10(3248800164u, 0x1.c1a4c0p+123f)
Struct11(0x1.c1a4c1a4c1a4cp+123, 3248800164u)
Struct12(0x1.c1a4c0p+123f, 3248800164u)
Struct13(0x1.c1a4c0p+123f)
Struct14(0x1.c1a4c0p+123f, 0x1.abcdeep+99f)
Struct15(0x1.c1a4c0p+123f, 0x1.abcdeep+99f, 0x1.010102p+10f)
Struct16(0x1.c1a4c0p+123f, 0x1.abcdeep+99f, 0x1.010102p+10f, 0x1.020202p+20f, 0x1.030302p+30f)
Struct17(0x1.c1a4c1a4c1a4cp+123)
Struct18(0x1.c1a4c1a4c1a4cp+123, 0x1.abcdefabcdefap+99)
Struct19(0x1.c1a4c1a4c1a4cp+123, 0x1.abcdefabcdefap+99, 0x1.0101010101010p+10)
Struct20(0x1.c1a4c1a4c1a4cp+123, 0x1.abcdefabcdefap+99, 0x1.0101010101010p+10, 0x1.0202020202020p+20)
Struct21(0x1.c1a4c1a4c1a4cp+123, 0x1.abcdefabcdefap+99, 0x1.0101010101010p+10, 0x1.0202020202020p+20, 0x1.0303030303030p+30)
3248800164u
0x1.c1a4c0p+123f
3248800164u
0x1.c1a4c1a4c1a4cp+123
3248800164u
0x1.c1a4c0p+123f+0x1.abcdeep+99fj
3248800164u
0x1.c1a4c1a4c1a4cp+123+0x1.abcdefabcdefap+99j
Passing Clay return values to C:
c1a4c1a4 1 0x1.c1a4cp+123 0x1.c1a4c1a4c1a4cp+123
0x1.c1a4cp+123,0x1.abcdeep+99
0x1.c1a4c1a4c1a4cp+123,0x1.abcdefabcdefap+99
c1a4c1a4c1a4c1a4
c1a4c1a4
c1a4c1a4 12345678
c1a4c1a4 12345678 abcdabcd
c1a4c1a4 12345678 abcdabcdabcdabcd
c1a4c1a4 abcdabcdabcdabcd
c1a4c1a4 abcdabcdabcdabcd 12345678
c1a4c1a4c1a4c1a4 abcdabcdabcdabcd 1234567812345678
c1a4c1a4 0x1.c1a4c1a4c1a4cp+123
c1a4c1a4 0x1.c1a4cp+123
0x1.c1a4c1a4c1a4cp+123 c1a4c1a4
0x1.c1a4cp+123 c1a4c1a4
0x1.c1a4cp+123
0x1.c1a4cp+123 0x1.abcdeep+99
0x1.c1a4cp+123 0x1.abcdeep+99 0x1.010102p+10
0x1.c1a4cp+123 0x1.abcdeep+99 0x1.010102p+10 0x1.020202p+20 0x1.030302p+30
0x1.c1a4c1a4c1a4cp+123
0x1.c1a4c1a4c1a4cp+123 0x1.abcdefabcdefap+99
0x1.c1a4c1a4c1a4cp+123 0x1.abcdefabcdefap+99 0x1.010101010101p+10
0x1.c1a4c1a4c1a4cp+123 0x1.abcdefabcdefap+99 0x1.010101010101p+10 0x1.020202020202p+20
0x1.c1a4c1a4c1a4cp+123 0x1.abcdefabcdefap+99 0x1.010101010101p+10 0x1.020202020202p+20 0x1.030303030303p+30
0: c1a4c1a4
1: 0x1.c1a4cp+123
0: c1a4c1a4
1: 0x1.c1a4c1a4c1a4cp+123
0: c1a4c1a4
1: 0x1.c1a4cp+123,0x1.abcdeep+99
0: c1a4c1a4
1: 0x1.c1a4c2p+123,0x1.abcdfp+99
Passing Clay arguments to C:
c1a4c1a4 1 0x1.c1a4cp+123 0x1.c1a4c1a4c1a4cp+123
0x1.c1a4cp+123,0x1.abcdeep+99
0x1.c1a4c1a4c1a4cp+123,0x1.abcdefabcdefap+99
c1a4c1a4c1a4c1a4
c1a4c1a4
c1a4c1a4 12345678
c1a4c1a4 12345678 abcdabcd
c1a4c1a4 12345678 abcdabcdabcdabcd
c1a4c1a4 abcdabcdabcdabcd
c1a4c1a4 abcdabcdabcdabcd 12345678
c1a4c1a4c1a4c1a4 abcdabcdabcdabcd 1234567812345678
c1a4c1a4 0x1.c1a4c1a4c1a4cp+123
c1a4c1a4 0x1.c1a4cp+123
0x1.c1a4c1a4c1a4cp+123 c1a4c1a4
0x1.c1a4cp+123 c1a4c1a4
0x1.c1a4cp+123
0x1.c1a4cp+123 0x1.abcdeep+99
0x1.c1a4cp+123 0x1.abcdeep+99 0x1.010102p+10
0x1.c1a4cp+123 0x1.abcdeep+99 0x1.010102p+10 0x1.020202p+20 0x1.030302p+30
0x1.c1a4c1a4c1a4cp+123
0x1.c1a4c1a4c1a4cp+123 0x1.abcdefabcdefap+99
0x1.c1a4c1a4c1a4cp+123 0x1.abcdefabcdefap+99 0x1.010101010101p+10
0x1.c1a4c1a4c1a4cp+123 0x1.abcdefabcdefap+99 0x1.010101010101p+10 0x1.020202020202p+20
0x1.c1a4c1a4c1a4cp+123 0x1.abcdefabcdefap+99 0x1.010101010101p+10 0x1.020202020202p+20 0x1.030303030303p+30
0: c1a4c1a4
1: 0x1.c1a4cp+123
0: c1a4c1a4
1: 0x1.c1a4c1a4c1a4cp+123
0: c1a4c1a4
1: 0x1.c1a4cp+123,0x1.abcdeep+99
0: c1a4c1a4
1: 0x1.c1a4c2p+123,0x1.abcdfp+99
Passing C return values to Clay:
3248800164u, true, 0x1.c1a4c0p+123f, 0x1.c1a4c1a4c1a4cp+123
0x1.c1a4c0p+123f+0x1.abcdeep+99fj
0x1.c1a4c1a4c1a4cp+123+0x1.abcdefabcdefap+99j
Struct1(13953490458868236708ul)
Struct2(3248800164u)
Struct3(3248800164u, 305419896u)
Struct4(3248800164u, 305419896u, 2882382797u)
Struct5(3248800164u, 305419896u, 12379739850550389709ul)
Struct6(3248800164u, 12379739850550389709ul)
Struct7(3248800164u, 12379739850550389709ul, 305419896u)
Struct8(13953490458868236708ul, 12379739850550389709ul, 1311768465173141112ul)
Struct9(3248800164u, 0x1.c1a4c1a4c1a4cp+123)
Struct10(3248800164u, 0x1.c1a4c0p+123f)
Struct11(0x1.c1a4c1a4c1a4cp+123, 3248800164u)
Struct12(0x1.c1a4c0p+123f, 3248800164u)
Struct13(0x1.c1a4c0p+123f)
Struct14(0x1.c1a4c0p+123f, 0x1.abcdeep+99f)
Struct15(0x1.c1a4c0p+123f, 0x1.abcdeep+99f, 0x1.010102p+10f)
Struct16(0x1.c1a4c0p+123f, 0x1.abcdeep+99f, 0x1.010102p+10f, 0x1.020202p+20f, 0x1.030302p+30f)
Struct17(0x1.c1a4c1a4c1a4cp+123)
Struct18(0x1.c1a4c1a4c1a4cp+123, 0x1.abcdefabcdefap+99)
Struct19(0x1.c1a4c1a4c1a4cp+123, 0x1.abcdefabcdefap+99, 0x1.0101010101010p+10)
Struct20(0x1.c1a4c1a4c1a4cp+123, 0x1.abcdefabcdefap+99, 0x1.0101010101010p+10, 0x1.0202020202020p+20)
Struct21(0x1.c1a4c1a4c1a4cp+123, 0x1.abcdefabcdefap+99, 0x1.0101010101010p+10, 0x1.0202020202020p+20, 0x1.0303030303030p+30)
3248800164u
0x1.c1a4c0p+123f
3248800164u
0x1.c1a4c1a4c1a4cp+123
3248800164u
0x1.c1a4c0p+123f+0x1.abcdeep+99fj
3248800164u
0x1.c1a4c1a4c1a4cp+123+0x1.abcdefabcdefap+99j
-------------
actual output
-------------
!! error code 1
----------------
expected err.txt
----------------
-------------
actual stderr
-------------
external_test.c:5:10: fatal error: 'complex.h' file not found
#include <complex.h>
^
1 error generated.
=====================
floats\literals\long
=====================
compiler error
--------------
###############################
main() {
println(repr(0x1.0000_0000_0000_0002p0l));
-----------------^
println(repr(0x1.0000_0000_0000_0001p0l));
println(repr(0x1.0000_0000_0000_0003p0l));
###############################
C:\Users\Joe\Documents\Code\clay\test\floats\literals\long\main.clay(4,17): error: invalid float80 literal
compilation context:
main()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,33):
getExitCode()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,26):
callMain(Static[main])
=====================
io\sockets\addresses
=====================
compiler error
--------------
###############################
overload lookupInetHostname(n: UInt32) --> s: In_addr {
s.s_addr <-- hostToNetwork(n);
-----^
}
###############################
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(125,5): error: no matching overload found
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\referencetypes\referencetypes.clay(87,0)
predicate "ReferenceType?(T) and (fieldNameIndex(T, Field) >= 0)" failed
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\referencetypes\referencetypes.clay(61,0)
predicate "ReferenceType?(T)" failed
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\statics\statics.clay(75,0)
pattern "<generated expression>" did not match type "Struct_in_addr" of argument 1
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\records\records.clay(8,0)
predicate "RecordWithField?(T, FIELD)" failed
83 universal overloads not shown (show with -full-match-errors option)
compilation context:
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\complex\complex.clay(92,15):
fieldRef(Struct_in_addr, Static[#s_addr])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(125,5):
lookupInetHostname(UInt32)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(97,29):
Inet(Struct_in_addr, UInt16)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(97,10):
Inet(UInt32, Int32)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(27,24):
expectSockaddrIn(TestStatus, StringConstant, UInt32, Int32, Inet)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(24,32):
<lambda C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(23,42)>(TestStatus)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\statics\statics.clay(67,15):
call(Static[<lambda C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(23,42)>], TestStatus)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\lambdas\lambdas.clay(73,33):
LambdaBody[(TestStatus), ()](Static[<lambda C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(23,42)>])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\lambdas\lambdas.clay(17,48):
new(LambdaBody[(TestStatus), ()])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\lambdas\lambdas.clay(17,29):
Lambda[(TestStatus), ()](SharedPointer[LambdaBody[(TestStatus), ()]])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\lambdas\lambdas.clay(17,25):
Lambda[(TestStatus), ()](Static[<lambda C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(23,42)>])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\test\test.clay(22,69):
TestCase(StringConstant, Lambda[(TestStatus), ()], Bool)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\test\test.clay(22,38):
TestCase(StringConstant, Static[<lambda C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(23,42)>])
C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(23,20):
Array[TestCase, 3](TestCase, TestCase, TestCase)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\arrays\arrays.clay(243,61):
array(TestCase, TestCase, TestCase)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(22,48):
TestSuite(StringConstant, Array[TestCase, 3])
C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(22,17):
testMain(TestSuite)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\addresses\test.clay(21,20):
main()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,33):
getExitCode(Int32)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,26):
callMain(Static[main])
=====================
io\sockets\connections
=====================
compiler error
--------------
###############################
overload lookupInetHostname(n: UInt32) --> s: In_addr {
s.s_addr <-- hostToNetwork(n);
-----^
}
###############################
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(125,5): error: no matching overload found
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\referencetypes\referencetypes.clay(87,0)
predicate "ReferenceType?(T) and (fieldNameIndex(T, Field) >= 0)" failed
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\referencetypes\referencetypes.clay(61,0)
predicate "ReferenceType?(T)" failed
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\statics\statics.clay(75,0)
pattern "<generated expression>" did not match type "Struct_in_addr" of argument 1
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\records\records.clay(8,0)
predicate "RecordWithField?(T, FIELD)" failed
83 universal overloads not shown (show with -full-match-errors option)
compilation context:
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\complex\complex.clay(92,15):
fieldRef(Struct_in_addr, Static[#s_addr])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(125,5):
lookupInetHostname(UInt32)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(97,29):
Inet(Struct_in_addr, UInt16)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(97,10):
Inet(UInt32, Int32)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\connections\main.clay(12,36):
ListenSocket(Inet)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\connections\main.clay(12,31):
server(Vector[Vector[Char]])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(90,33):
invokeCommand(Static[server], Vector[Vector[Char]])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(100,36):
call(<lambda C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,27)>, Vector[Char])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\maybe\maybe.clay(46,77):
maybeValue(Static[Vector[Char]], Vector[Char], <lambda C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,27)>, Static[(() => usage(..commandTuples))])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\maybe\maybe.clay(57,26):
maybeValue(Static[Vector[Char]], Maybe[Vector[Char]], <lambda C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,27)>, Static[(() => usage(..commandTuples))])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\maybe\maybe.clay(57,26):
maybe(Maybe[Vector[Char]], <lambda C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,27)>, Static[(() => usage(..commandTuples))])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,16):
dispatchMain(Static[server], Static[client])
C:\Users\Joe\Documents\Code\clay\test\io\sockets\connections\main.clay(7,24):
main()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,33):
getExitCode(Int32)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,26):
callMain(Static[main])
=====================
io\sockets\reading
=====================
compiler error
--------------
###############################
overload lookupInetHostname(n: UInt32) --> s: In_addr {
s.s_addr <-- hostToNetwork(n);
-----^
}
###############################
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(125,5): error: no matching overload found
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\referencetypes\referencetypes.clay(87,0)
predicate "ReferenceType?(T) and (fieldNameIndex(T, Field) >= 0)" failed
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\referencetypes\referencetypes.clay(61,0)
predicate "ReferenceType?(T)" failed
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\statics\statics.clay(75,0)
pattern "<generated expression>" did not match type "Struct_in_addr" of argument 1
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\records\records.clay(8,0)
predicate "RecordWithField?(T, FIELD)" failed
83 universal overloads not shown (show with -full-match-errors option)
compilation context:
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\complex\complex.clay(92,15):
fieldRef(Struct_in_addr, Static[#s_addr])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(125,5):
lookupInetHostname(UInt32)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(97,29):
Inet(Struct_in_addr, UInt16)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(97,10):
Inet(UInt32, Int32)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\reading\main.clay(13,36):
ListenSocket(Inet)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\reading\main.clay(13,31):
server(Vector[Vector[Char]])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(90,33):
invokeCommand(Static[server], Vector[Vector[Char]])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(100,36):
call(<lambda C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,27)>, Vector[Char])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\maybe\maybe.clay(46,77):
maybeValue(Static[Vector[Char]], Vector[Char], <lambda C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,27)>, Static[(() => usage(..commandTuples))])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\maybe\maybe.clay(57,26):
maybeValue(Static[Vector[Char]], Maybe[Vector[Char]], <lambda C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,27)>, Static[(() => usage(..commandTuples))])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\maybe\maybe.clay(57,26):
maybe(Maybe[Vector[Char]], <lambda C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,27)>, Static[(() => usage(..commandTuples))])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\commandline\dispatch\dispatch.clay(97,16):
dispatchMain(Static[server], Static[client])
C:\Users\Joe\Documents\Code\clay\test\io\sockets\reading\main.clay(7,24):
main()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,33):
getExitCode(Int32)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,26):
callMain(Static[main])
=====================
io\sockets\valuesemantics
=====================
compiler error
--------------
###############################
overload lookupInetHostname(n: UInt32) --> s: In_addr {
s.s_addr <-- hostToNetwork(n);
-----^
}
###############################
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(125,5): error: no matching overload found
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\referencetypes\referencetypes.clay(87,0)
predicate "ReferenceType?(T) and (fieldNameIndex(T, Field) >= 0)" failed
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\referencetypes\referencetypes.clay(61,0)
predicate "ReferenceType?(T)" failed
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\statics\statics.clay(75,0)
pattern "<generated expression>" did not match type "Struct_in_addr" of argument 1
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\records\records.clay(8,0)
predicate "RecordWithField?(T, FIELD)" failed
82 universal overloads not shown (show with -full-match-errors option)
compilation context:
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\complex\complex.clay(92,15):
fieldRef(Struct_in_addr, Static[#s_addr])
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(125,5):
lookupInetHostname(UInt32)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(97,29):
Inet(Struct_in_addr, UInt16)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\io\sockets\sockets.clay(97,10):
Inet(UInt32, Int32)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\valuesemantics\main.clay(4,29):
ListenSocket(Inet)
C:\Users\Joe\Documents\Code\clay\test\io\sockets\valuesemantics\main.clay(4,24):
main()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,33):
getExitCode()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,26):
callMain(Static[main])
=====================
lua\capi\claytolua
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-541068 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _lua_pcall referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _lua_getfield referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _lua_pushnumber referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _lua_call referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _lua_tonumber referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _lua_settop referenced in function _main
clayobj.obj-541068 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
test.exe : fatal error LNK1120: 10 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib'
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
lua\capi\luahello
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-015442 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-015442 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-015442 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-015442 : error LNK2019: unresolved external symbol _lua_pcall referenced in function _main
clayobj.obj-015442 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
test.exe : fatal error LNK1120: 5 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib'
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
lua\capi\luatoclay
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-349197 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-349197 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_pushcclosure referenced in function _main
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_setfield referenced in function _main
clayobj.obj-349197 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_pcall referenced in function _main
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_gettop referenced in function _clay_errorNoThrow_28_StringConstant_2C__20_Static_5B_integerAddWithOverflow_5D__2C__20_StringConstant_2C__20_ReprFormatter_5B_Tuple_5B_CapturedLValue_5B_Int32_5D__2C__20_CapturedLValue_5B_Int32_5D__5D__5D__2C__20_StringConstant_29_
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_pushstring referenced in function _clay_errorNoThrow_28_StringConstant_2C__20_Static_5B_integerAddWithOverflow_5D__2C__20_StringConstant_2C__20_ReprFormatter_5B_Tuple_5B_CapturedLValue_5B_Int32_5D__2C__20_CapturedLValue_5B_Int32_5D__5D__5D__2C__20_StringConstant_29_
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_error referenced in function _clay_errorNoThrow_28_StringConstant_2C__20_Static_5B_integerAddWithOverflow_5D__2C__20_StringConstant_2C__20_ReprFormatter_5B_Tuple_5B_CapturedLValue_5B_Int32_5D__2C__20_CapturedLValue_5B_Int32_5D__5D__5D__2C__20_StringConstant_29_
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_isnumber referenced in function _clay_errorNoThrow_28_StringConstant_2C__20_Static_5B_integerAddWithOverflow_5D__2C__20_StringConstant_2C__20_ReprFormatter_5B_Tuple_5B_CapturedLValue_5B_Int32_5D__2C__20_CapturedLValue_5B_Int32_5D__5D__5D__2C__20_StringConstant_29_
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_tonumber referenced in function _clay_errorNoThrow_28_StringConstant_2C__20_Static_5B_integerAddWithOverflow_5D__2C__20_StringConstant_2C__20_ReprFormatter_5B_Tuple_5B_CapturedLValue_5B_Int32_5D__2C__20_CapturedLValue_5B_Int32_5D__5D__5D__2C__20_StringConstant_29_
clayobj.obj-349197 : error LNK2019: unresolved external symbol _lua_pushnumber referenced in function _clay_errorNoThrow_28_StringConstant_2C__20_Static_5B_integerAddWithOverflow_5D__2C__20_StringConstant_2C__20_ReprFormatter_5B_Tuple_5B_CapturedLValue_5B_Int32_5D__2C__20_CapturedLValue_5B_Int32_5D__5D__5D__2C__20_StringConstant_29_
test.exe : fatal error LNK1120: 13 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib' [warn_drv_unused_argument]
clang: error: linker command failed with exit code 1120 (use -v to see invocation) [err_drv_command_failed]
=====================
lua\highlevel\claytolua
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-756211 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-756211 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-756211 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-756211 : error LNK2019: unresolved external symbol _lua_tolstring referenced in function _main
clayobj.obj-756211 : error LNK2019: unresolved external symbol _lua_pushnumber referenced in function _main
clayobj.obj-756211 : error LNK2019: unresolved external symbol _lua_tointeger referenced in function _main
clayobj.obj-756211 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-756211 : error LNK2019: unresolved external symbol _lua_settop referenced in function _clay_lua_pop_28_Pointer_5B_UInt8_5D__2C__20_Int32_29_
clayobj.obj-756211 : error LNK2019: unresolved external symbol _lua_atpanic referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20__7B__20_lua_call_28_x.handle_2C__20_nargs_2C__20_nresults_29__3B__20__7D__29__29_
clayobj.obj-756211 : error LNK2019: unresolved external symbol _lua_call referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20__7B__20_lua_call_28_x.handle_2C__20_nargs_2C__20_nresults_29__3B__20__7D__29__29_
clayobj.obj-756211 : error LNK2019: unresolved external symbol _lua_getfield referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
test.exe : fatal error LNK1120: 11 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib'
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
lua\highlevel\customtype1
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-031165 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-031165 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-031165 : error LNK2019: unresolved external symbol _luaL_register referenced in function _main
clayobj.obj-031165 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_tolstring referenced in function _main
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_settop referenced in function _main
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_newuserdata referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_atpanic referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkint_28_x.handle_2C__20_index_29__20__29__29_
clayobj.obj-031165 : error LNK2019: unresolved external symbol _luaL_checkinteger referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkint_28_x.handle_2C__20_index_29__20__29__29_
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_pushlstring referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_error referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-031165 : error LNK2019: unresolved external symbol _luaL_typerror referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20__7B__20_luaL_typerror_28_x.handle_2C__20_index_2C__20_cstring_28_expected_29__29__3B__20__7D__29__29_
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_touserdata referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20__7B__20_luaL_typerror_28_x.handle_2C__20_index_2C__20_cstring_28_expected_29__29__3B__20__7D__29__29_
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_pushinteger referenced in function _clay_IntArray_get_28_State_29_
clayobj.obj-031165 : error LNK2019: unresolved external symbol _lua_call referenced in function _clay_IntArray_size_28_State_29_
test.exe : fatal error LNK1120: 16 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib' [warn_drv_unused_argument]
clang: error: linker command failed with exit code 1120 (use -v to see invocation) [err_drv_command_failed]
=====================
lua\highlevel\customtype2
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-654664 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-654664 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-654664 : error LNK2019: unresolved external symbol _luaL_newmetatable referenced in function _main
clayobj.obj-654664 : error LNK2019: unresolved external symbol _luaL_register referenced in function _main
clayobj.obj-654664 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_tolstring referenced in function _main
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_settop referenced in function _clay_lua_pop_28_Pointer_5B_UInt8_5D__2C__20_Int32_29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_newuserdata referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_getfield referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_setmetatable referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_atpanic referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkint_28_x.handle_2C__20_index_29__20__29__29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _luaL_checkinteger referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkint_28_x.handle_2C__20_index_29__20__29__29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_pushlstring referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_error referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _luaL_checkudata referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkudata_28_x.handle_2C__20_index_2C__20_cstring_28_tname_29__29__20__29__29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_pushinteger referenced in function _clay_IntArray_get_28_State_29_
clayobj.obj-654664 : error LNK2019: unresolved external symbol _lua_call referenced in function _clay_IntArray_get_28_State_29_
test.exe : fatal error LNK1120: 18 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib'
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
lua\highlevel\customtype3
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-498283 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _luaL_newmetatable referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_pushvalue referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_setfield referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _luaL_register referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_tolstring referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_settop referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_atpanic referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkudata_28_x.handle_2C__20_index_2C__20_cstring_28_tname_29__29__20__29__29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _luaL_checkudata referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkudata_28_x.handle_2C__20_index_2C__20_cstring_28_tname_29__29__20__29__29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _luaL_checkinteger referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_pushlstring referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_error referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_pushinteger referenced in function _clay_IntArray_get_28_State_29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_newuserdata referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_getfield referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_setmetatable referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-498283 : error LNK2019: unresolved external symbol _lua_call referenced in function _clay_IntArray_new_28_State_29_
test.exe : fatal error LNK1120: 20 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib'
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
lua\highlevel\customtype4
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-292385 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-292385 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-292385 : error LNK2019: unresolved external symbol _luaL_newmetatable referenced in function _main
clayobj.obj-292385 : error LNK2019: unresolved external symbol _luaL_register referenced in function _main
clayobj.obj-292385 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_tolstring referenced in function _main
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_settop referenced in function _main
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_pushlstring referenced in function _clay_IntArray_tostring_28_State_29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_atpanic referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkudata_28_x.handle_2C__20_index_2C__20_cstring_28_tname_29__29__20__29__29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _luaL_checkudata referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkudata_28_x.handle_2C__20_index_2C__20_cstring_28_tname_29__29__20__29__29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_error referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_pushinteger referenced in function _clay_IntArray_get_28_State_29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _luaL_checkinteger referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkint_28_x.handle_2C__20_index_29__20__29__29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_newuserdata referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_getfield referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_setmetatable referenced in function _clay_IntArray_new_28_State_29_
clayobj.obj-292385 : error LNK2019: unresolved external symbol _lua_call referenced in function _clay_IntArray_new_28_State_29_
test.exe : fatal error LNK1120: 18 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib'
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
lua\highlevel\customtype5
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-900079 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _luaL_newmetatable referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_pushnumber referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_setfield referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _luaL_register referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_tolstring referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_atpanic referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkudata_28_x.handle_2C__20_index_2C__20_cstring_28_tname_29__29__20__29__29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _luaL_checkudata referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checkudata_28_x.handle_2C__20_index_2C__20_cstring_28_tname_29__29__20__29__29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_pushlstring referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_error referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_createtable referenced in function _clay_Point_xyArray_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_rawseti referenced in function _clay_Point_xyArray_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_settop referenced in function _clay_Point_xyArray_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_getfield referenced in function _clay_Point_index_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_pushvalue referenced in function _clay_Point_index_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_rawget referenced in function _clay_Point_index_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_isnumber referenced in function _clay_Point_index_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_tointeger referenced in function _clay_Point_index_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_type referenced in function _clay_Point_index_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _luaL_typerror referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20__7B__20_luaL_typerror_28_x.handle_2C__20_index_2C__20_cstring_28_expected_29__29__3B__20__7D__29__29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_tonumber referenced in function _clay_Point_newIndex_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_newuserdata referenced in function _clay_Point_new_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_setmetatable referenced in function _clay_Point_new_28_State_29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _luaL_checknumber referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checknumber_28_x.handle_2C__20_index_29__20__29__29_
clayobj.obj-900079 : error LNK2019: unresolved external symbol _lua_call referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checknumber_28_x.handle_2C__20_index_29__20__29__29_
test.exe : fatal error LNK1120: 28 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib' [warn_drv_unused_argument]
clang: error: linker command failed with exit code 1120 (use -v to see invocation) [err_drv_command_failed]
=====================
lua\highlevel\luahello
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-036107 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-036107 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-036107 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-036107 : error LNK2019: unresolved external symbol _lua_tolstring referenced in function _main
clayobj.obj-036107 : error LNK2019: unresolved external symbol _lua_settop referenced in function _main
clayobj.obj-036107 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-036107 : error LNK2019: unresolved external symbol _lua_atpanic referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20__7B__20_lua_call_28_x.handle_2C__20_nargs_2C__20_nresults_29__3B__20__7D__29__29_
clayobj.obj-036107 : error LNK2019: unresolved external symbol _lua_call referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20__7B__20_lua_call_28_x.handle_2C__20_nargs_2C__20_nresults_29__3B__20__7D__29__29_
test.exe : fatal error LNK1120: 8 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib' [warn_drv_unused_argument]
clang: error: linker command failed with exit code 1120 (use -v to see invocation) [err_drv_command_failed]
=====================
lua\highlevel\luatoclay
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/llua'; ignored
clayobj.obj-531068 : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _main
clayobj.obj-531068 : error LNK2019: unresolved external symbol _luaL_openlibs referenced in function _main
clayobj.obj-531068 : error LNK2019: unresolved external symbol _luaL_register referenced in function _main
clayobj.obj-531068 : error LNK2019: unresolved external symbol _luaL_loadstring referenced in function _main
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_tolstring referenced in function _main
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_settop referenced in function _main
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_close referenced in function _main
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_pushlstring referenced in function _clay_exceptionAs_28_Static_5B_Error_5D__2C__20_Pointer_5B_UInt8_5D__29_
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_error referenced in function _clay_exceptionAs_28_Static_5B_Error_5D__2C__20_Pointer_5B_UInt8_5D__29_
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_gettop referenced in function _clay_sumAndAverage_28_State_29_
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_pushnumber referenced in function _clay_sumAndAverage_28_State_29_
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_atpanic referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checknumber_28_x.handle_2C__20_index_29__20__29__29_
clayobj.obj-531068 : error LNK2019: unresolved external symbol _luaL_checknumber referenced in function _clay_safeCall_28_State_2C__20__28_x_20__2D__3E__20_luaL_checknumber_28_x.handle_2C__20_index_29__20__29__29_
clayobj.obj-531068 : error LNK2019: unresolved external symbol _lua_call referenced in function _clay_cwrapper_panicHandler_28_Pointer_5B_UInt8_5D__29_
test.exe : fatal error LNK1120: 14 unresolved externals
clang: warning: argument unused during compilation: '-L/opt/local/lib'
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
math\1
=====================
compiler error
--------------
###############################
import libc.(csqrtf, crealf, cimagf);
-------------^
import math.(sqrt);
import printer.formatter.(repr);
###############################
C:\Users\Joe\Documents\Code\clay\test\math\1\main.clay(1,13): error: imported name not found
=====================
numbers\parser\1
=====================
compiler error
--------------
###############################
external strtold(
argument0 : Pointer[CChar],
argument1 : Pointer[Pointer[CChar]]) : UnsupportedCBuiltinType22;
-------------------------------------------^
external strtol(
###############################
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\libc\generated\generated.windows.32.clay(681,43): error: undefined name: UnsupportedCBuiltinType22
compilation context:
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\numbers\parser\parser.clay(145,23):
parseFloat80(StringConstant)
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\numbers\numbers.clay(412,43):
Float80(StringConstant)
C:\Users\Joe\Documents\Code\clay\test\numbers\parser\1\main.clay(8,19):
main()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,33):
getExitCode()
C:/Users/Joe/Documents/Code/clay/build/compiler/src/../../../lib-clay\system\system.clay(32,26):
callMain(Static[main])
=====================
numbers\parser\4
=====================
compiler error
--------------
clayobj.obj-929020 : error LNK2019: unresolved external symbol _strtof referenced in function _main
test.exe : fatal error LNK1120: 1 unresolved externals
clang: error: linker command failed with exit code 1120 (use -v to see invocation) [err_drv_command_failed]
=====================
parsing
=====================
compiler error
--------------
clayobj.obj-121145 : error LNK2019: unresolved external symbol _strtoll referenced in function _clay_call_28__3C_lambda_20_C_3A__2F_Users_2F_Joe_2F_Documents_2F_Code_2F_clay_2F_build_2F_compiler_2F_src_2F_.._2F_.._2F_.._2F_lib_2D_clay_5C_parsing_5C_combinators_5C_generic_5C_generic.clay_28_235_2C_11_29__3E__2C__20_CoordinateRange_5B_Pointer_5B_Char_5D__5D__29_
test.exe : fatal error LNK1120: 1 unresolved externals
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
printing\int128
=====================
compiler error
--------------
UNREACHABLE executed!
=====================
remote\messages\simple
=====================
out.txt mismatch
expected out.txt
----------------
-- server stderr
Hello from Server!
Hello from Lambda!
arguments from client:
* zim
* zang
* zung
-- client stderr
-------------
actual output
-------------
-- server stderr
Hello from Server!
Hello from Lambda!
arguments from client:
* zim
* zang
* zung
unhandled exception: error(109): The pipe has been ended.
-- client stderr
=====================
sqlite
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/lsqlite3'; ignored
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_open referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_errmsg referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_close referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_exec referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_last_insert_rowid referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_step referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_db_handle referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_column_text referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_column_int referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_finalize referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_bind_int referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_bind_null referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_column_type referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_reset referenced in function _clay_main_28__29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_prepare_v2 referenced in function _clay_SqliteStatement_28_SqliteDB_2C__20_StringConstant_29_
clayobj.obj-763778 : error LNK2019: unresolved external symbol _sqlite3_bind_text referenced in function _clay_bindStatement_28_SqliteStatement_2C__20_Int32_2C__20_StringConstant_29_
test.exe : fatal error LNK1120: 16 unresolved externals
clang: error: linker command failed with exit code 1120 (use -v to see invocation) [err_drv_command_failed]
=====================
sqlite\sequences
=====================
compiler error
--------------
LINK : warning LNK4044: unrecognized option '/lsqlite3'; ignored
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_open referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_errmsg referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_close referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_exec referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_prepare_v2 referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_finalize referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_step referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_db_handle referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_column_int referenced in function _clay_main_28__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_reset referenced in function _clay_runStatement_28_SqliteStatement_2C__20_StringConstant_29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_bind_text referenced in function _clay_bindStatementValues_28_SqliteStatement_2C__20_StringConstant_29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_bind_parameter_index referenced in function _clay_printTo_28_RawFile_2C__20_Static_5B__23_ic32c62c61c320c32andc32SizeTc40ic41c32c60c32sizec40ac41_5D__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_bind_int referenced in function _clay_printTo_28_RawFile_2C__20_Static_5B__23_ic32c62c61c320c32andc32SizeTc40ic41c32c60c32sizec40ac41_5D__29_
clayobj.obj-247708 : error LNK2019: unresolved external symbol _sqlite3_column_text referenced in function _clay_printTo_28_RawFile_2C__20_Static_5B__23_ic32c62c61c320c32andc32SizeTc40ic41c32c60c32sizec40ac41_5D__29_
test.exe : fatal error LNK1120: 14 unresolved externals
clang: error: linker command failed with exit code 1120 (use -v to see invocation)
=====================
uncategorized\41
=====================
compiler error
--------------
clayobj.obj-714417 : error LNK2019: unresolved external symbol _strtoll referenced in function _clay_main_28__29_
clayobj.obj-714417 : error LNK2019: unresolved external symbol _strtoull referenced in function _clay_errorNoThrow_28_StringConstant_2C__20_StringConstant_2C__20_UInt32_2C__20_StringConstant_2C__20_UInt32_2C__20_StringConstant_2C__20_Static_5B__23_validVectorCoordinatec63c40ac44c32jc41_5D__2C__20_StringConstant_2C__20_StringConstant_2C__20_Static_5B_Vector_5B_Char_5D__5D__29_
clayobj.obj-714417 : error LNK2019: unresolved external symbol _strtof referenced in function _clay_errorNoThrow_28_StringConstant_2C__20_StringConstant_2C__20_UInt32_2C__20_StringConstant_2C__20_UInt32_2C__20_StringConstant_2C__20_Static_5B__23_validVectorCoordinatec63c40ac44c32jc41_5D__2C__20_StringConstant_2C__20_StringConstant_2C__20_Static_5B_Vector_5B_Char_5D__5D__29_
test.exe : fatal error LNK1120: 3 unresolved externals
clang: error: linker command failed with exit code 1120 (use -v to see invocation) [err_drv_command_failed]
=====================
uncategorized\7
=====================
compiler error
--------------
clayobj.obj-422932 : error LNK2019: unresolved external symbol _fdopen referenced in function _main
test.exe : fatal error LNK1120: 1 unresolved externals
clang: error: linker command failed with exit code 1120 (use -v to see invocation) [err_drv_command_failed]
uninitialized(T)
already exists to give an uninitialized value. Int()
and friends should initialize to zero (or potentially nan for floats).
C functions are monomorphic and C APIs often have weak integer type discipline, so it would be convenient for call(CCodePointer, ..)
to perform the same implicit conversions as C automatically.
To make developing and distributing Clay libraries easier, the compiler should be able to programmatically generate Clay interface modules or C headers derived from the external
definitions included in the compilation unit.
Should add wrapAdd(), wrapSubtract(), etc. functions that allow for wraparound even with -Dclay.IntegerOverflowChecks
enabled, so that algorithms that intend to use modular math can still be written easily.
A legacy of the old fast-and-loose tuple pattern matching code I haven't been able to purge:
[..X] overload foo(static Thingy[[..X]]) { println(repr(..X)); }
main() {
foo(Thingy[Int]); // should not match, but does
}
The exception mechanism stores the current exception in a global variable, which is facepalmingly stupid. throwValue
should malloc space for the exception object, and the exception state should be passed as a pointer instead of a boolean.
Example, test.h:
struct foo {
int external;
};
produces the following code:
/* automatically generated by clay-bindgen */
record Struct_foo (
external : Int,
);
which fails with a parse error.
I'm not sure what the correct course of action would be. Maybe mangle everything that clashes with keywords to something like originallyExternal
?
On Arch Linux, cmake picks /usr/bin/python
, which is a symlink to /usr/bin/python3
, but the python script that make test
uses needs /usr/bin/python2
.
A simple workaround is to edit CMakeCache.txt and change it to the right python, but it took a little digging to find that as a cmake noob.
Instead of interleaving the instance types and lambdas:
match(variant, Inst1, i1 -> { .. }, Inst2, i2 -> { .. });
The match function would be cleaner if it dispatched matching based on the lambda signature:
match(variant, (i1:Inst1) -> { .. }, (i2:Inst2) -> { .. });
which would look nice with block syntax:
match(variant): (i1:Inst1) -> {
..
}, (i2:Inst2) -> {
..
}
They should use LARGE_INTEGER, but because bindgen is broken, it maps LARGE_INTEGER to the wrong types (Byte on win32, Int on Win64).
Empty variants can't really exist, but the compiler doesn't raise an error until it sees a dispatch operation applied to a variant. It should raise the error when the type is instantiated.
Inline-asm-inside-llvm sucks
Static[x] and variants or records containing Static[x] members can't be used as hashtable keys because hash(Static[x])
is missing.
The new bindgen aliases generated enum types to the correct corresponding C integer type. However, it doesn't emit the corresponding enum constants as the correct type, so they need to be cast when used in conjunction with the enum type.
Clay 0.1 now uses define foo(x:T, y:U);
as syntax for defining a generic function interface, and define foo(x:T, y:U) { ... }
with a body is invalid. clayfix needs to update code that placed the optional procedure
keyword before a full definition.
// 0.0
procedure foo;
procedure bar(x,y) = x + y;
// 0.1
define foo;
bar(x,y) = x + y;
The compiler should optionally generate source-level debug metadata. See http://llvm.org/docs/SourceLevelDebugging.html for a reference.
If you do the following in emac's clay-mode, it won't indent correctly.
// happens with any braces
void main() {
}
After you put this in, if you go to the center and press tab, it will not indent. It only happens when you close the brace before typing. If you tab and type a line of code into the middle area then it will work. It only doesn't work if the closing brace is there before indenting.
It's annoying when your coding style is "function, braces, close braces, then type body".
The following struct is defined/typedefd in glib/gthread.h:
typedef struct _GMutex GMutex;
That's all there is; it's supposed to be opaque.
Bindgen on the other hand generates the following failing code:
alias GMutex = Struct__GMutex;
I thinks something like alias Struct__GMutex = Opaque;
or alias GMutex = Opaque;
should be generated.
LLVM treats a function that returns { f64, f64 }
(or any struct containing float types) as returning each floating-point element on the x87 stack, which doesn't match the C ABI.
Normal return is ret i8* null
instead of ret i32 0
now. clayfix should be able to do an automatic subtitution in __llvm__
blocks.
I was thinking overflow was expected behavior for left shift, but the people have spoken, and they want left shift to be checked. Add overflow checks to bitshl
when enabled, and add a wrapBitshl
function which gives unchecked two's-complement overflow behavior.
foo(x:Maybe) { }
should raise an error.
The libc
and unix
bindings for FreeBSD and Windows need to be updated to include C99 math entry points for the math
library.
UInt(Int)
and friends should check for overflow when -Dclay.IntegerOverflowChecks
is enabled. There should be a wrapCast(static T, U)
function for cases when truncation is intended.
Windows has CaptureStackBackTrace
to capture backtrace information, but I'm not sure what the equivalent of backtrace_symbols
is to present the data.
CallDefined?
is janky and doesn't deal with value kinds properly. A better primitive would be a SFINAE companion to Type
, for which I like the name Can?
:
[A, B | CallDefined?(add, A, B)] foo(a:A, b:B) = a + b;
[| Can?(a + b)] foo(a, b) = a + b;
To be useful, it would have to be possible for the predicate to refer to runtime argument names for type propagation purposes. However, it would be an error to actually evaluate a runtime argument.
Can?
could also obviate the need for the gross typeToLValue
and typeToRValue
functions by accepting a monomorphic lambda, as in:
Sequence?(S) = Can?((s:S) -> iterator(s));
On a related note, it would also be useful to have Monomorphic?
and MonomorphicInputTypes
introspection for monomorphic lambdas and functions. These could be applied to allow things like the CodePointer
constructor to infer the input and output types when applied to a monomorphic lambda or function:
CodePointer[[T, U, V], [W]]((t, u, v) -> w)
CodePointer((t:T, u:U, v:V) -> w)
It would be useful to be able to overload and
and or
for Maybe
, Either
, and other monadic types:
var x = maybeA() and maybeB() and maybeC(); // short-circuit maybe chaining (aka ">>=")
var y = maybeA() or maybeB(); // maybe alternation (aka "mplus")
var z = maybeA() or 0; // maybe unpack with default
Specifically, it generates multiple instances of one struct. Error message:
###############################
external (cdecl) recvmmsg(arg0:Int, arg1:Pointer[Struct_mmsghdr], arg2:UInt, arg3:Int, arg4:Pointer[Struct_timespec]) : Int;
alias Struct_mmsghdr = Opaque;
------^
external (cdecl) sendmmsg(arg0:Int, arg1:Pointer[Struct_mmsghdr], arg2:UInt, arg3:Int) : Int;
###############################
/home/philipp/programming/clay/build/compiler/src/../../../lib-clay/unix/generated/generated.linux.64.clay(1503,6): error: name redefined: Struct_mmsghdr
Excerpt of the generated file:
alias Struct_mmsghdr = Opaque;
external (cdecl) recvmmsg(arg0:Int, arg1:Pointer[Struct_mmsghdr], arg2:UInt, arg3:Int, arg4:Pointer[Struct_timespec]) : Int;
alias Struct_mmsghdr = Opaque;
external (cdecl) sendmmsg(arg0:Int, arg1:Pointer[Struct_mmsghdr], arg2:UInt, arg3:Int) : Int;
This gets generated from the file <bits/socket.h>:
#ifdef __USE_GNU
/* For `recvmmsg'. */
struct mmsghdr
{
struct msghdr msg_hdr; /* Actual message header. */
unsigned int msg_len; /* Number of received bytes for the entry. */
};
#endif
[...]
/* Receive up to VLEN messages as described by VMESSAGES from socket FD.
Returns the number of bytes read or -1 for errors.
This function is a cancellation point and therefore not marked with
__THROW. */
extern int recvmmsg (int __fd, struct mmsghdr *__vmessages,
unsigned int __vlen, int __flags,
__const struct timespec *__tmo);
/* Send a VLEN messages as described by VMESSAGES to socket FD.
Return the number of datagrams successfully written or -1 for errors.
This function is a cancellation point and therefore not marked with
__THROW. */
extern int sendmmsg (int __fd, struct mmsghdr *__vmessages,
unsigned int __vlen, int __flags);
After removing the duplicate definition, everything works.
I'm not quite sure what is happening here. Apparently bindgen doesn't pick up the mmsghdr struct (because it doesn't define __USE_GNU?).
Just a reminder, when 0.1 is ready for release, to remove the -WIP tags from the version information in the compiler, tools, and docs.
From Elrood, when building LLVM 3.0 and Clay 0.1 on Windows with MSVC:
load time = 2140.72 ms
compile time = 420.577 ms
optimization time = 976.115 ms
codegen time = 317.49 ms
The cmake rule should check for the correct LLVM version and bail early.
It should be possible to bind multiple-value variables.
var zero, one, ..rest = integers(static 10);
clay-bindgen
currently depends on clang's fragile internal C++ interfaces. It should use the stable libclang
C interface.
In most cases it's not very interesting that random [F] F()
overloads didn't match a typical call site. call()
overloads are also uninteresting for static callables. Match errors should prune those error entries unless the compiler is given a -full-match-errors
flag.
A few stupid bugs that shouldn't have been lingering have slipped by
An eval
statement currently cannot generate goto
labels.
Since the compiler now supports C ABIs, we need a distinct llvm
ABI for interfacing with intrinsics and non-C LLVM code.
The problem is, that the -ldl flag is included in the LLVM_LDFLAGS and not in the LLVM_LIBS. The LDFLAGS are added to the front of the command line, but the -ldl should be at the end to link correctly. (The linker command can be seen in ./build/compiler/src/CMakeFiles/clay.dir/link.txt).
As a quick fix/hack, it is possible to add the dl library explicitely in the same way as the rt library (in ./compiler/src/CMakeLists.txt).
% ./build/compiler/src/clay -Ilib-clay -e 'println(1 + "2");'
###############################
-------------------^
###############################
-e(1,19): error: no matching overload found
Really no reason to allow both.
The following struct from gst/gstmessage.h:
struct _GstMessage
{
GstMiniObject mini_object;
/*< private >*//* with MESSAGE_LOCK */
GMutex *lock; /* lock and cond for async delivery */
GCond *cond;
/*< public > *//* with COW */
GstMessageType type;
guint64 timestamp;
GstObject *src;
GstStructure *structure;
/*< private >*/
union {
struct {
guint32 seqnum;
} ABI;
/* + 0 to mark ABI change for future greppage */
gpointer _gst_reserved[GST_PADDING + 0];
} abidata;
};
gets generated as:
record Struct__GstMessage (
mini_object : GstMiniObject,
lock : Pointer[GMutex],
cond : Pointer[GCond],
type : GstMessageType,
timestamp : guint64,
src : Pointer[GstObject],
structure : Pointer[GstStructure],
abidata : Union_Unnamed44,
);
without any mention of a Union_Unnamed44
anywhere else.
In a function definition like:
foo() : Int, Bool = ..bar();
The ..
is required. Since the return type declaration Int, Bool
makes it obvious that multiple returns are wanted, the ..
should be implied, as it is for multiple variable bindings such as var x, y = bar();
alias foo(x) { ... }
bar(x:Variant) { foo(*x); }
fails with a "dispatch cannot be used in this context" or similar error. Dispatch should be expanded normally into a switch over instances of the alias
function, before it is analyzed as call-by-name, since mechanically, dispatch happens before the call.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.