Path: news.cs.au.dk!olm From: olm@cs.au.dk (Ole Lehrmann Madsen) Newsgroups: comp.lang.beta Subject: Re: Is Beta a statically typed language? Date: 13 Jan 1999 22:14:43 GMT Organization: University of Aarhus, Department of Computer Science (DAIMI) Lines: 68 Message-ID: <77j5sj$1jo$1@xinwen.cs.au.dk> References: <77b7fc$l2o$1@xinwen.cs.au.dk> <369CEDC6.1A6561AE@thestar.ca> NNTP-Posting-Host: ariel.cs.au.dk X-Trace: xinwen.cs.au.dk 916265683 1656 255.255.255.255 (13 Jan 1999 22:14:43 GMT) X-Complaints-To: news@cs.au.dk NNTP-Posting-Date: 13 Jan 1999 22:14:43 GMT X-Newsreader: NN version 6.5.3 (NOV) Xref: news.cs.au.dk comp.lang.beta:11790 In <369CEDC6.1A6561AE@thestar.ca> Karl Waclawek writes: >Jean-Louis Leroy wrote: >> (# >> Person: (# #); >> people: @Set (# element:: Person #); >> backdoor: ^Set >> do >> &Person[]->people.insert; >> people[]->backdoor[]; (* no warning *) >> &integerObject[]->backdoor.insert (* trouble *) >> #) >I think the compiler is supposed to give a warning here, but it didn't >when I tried it. I even used the explicit --warn and --warnQua options. I just tried the example and the compiler gives a qua- warning. Please let us know more details if you don't get a warning. I have tried release r4.1.1 and never releases and they all give a warning. I have included the example and compiler output in this message. ---olm Example program: origin '~beta/basiclib/v1.6/betaenv'; include '~beta/containers/v1.6/sets' ---program:descriptor--- (# Person: (# #); people: @Set (# element:: Person #); backdoor: ^Set do &Person[]->people.insert; people[]->backdoor[]; (* no warning *) &integerObject[]->backdoor.insert (* trouble *) #) Compiler output: Mjolner BETA Compiler version 5.3(4) for SUN-4 Solaris 2.x (ELF) Target machine type sun4s Building dependency graph for: 'jll' ... Parsing: 'jll' Translating fragments ... Bind fragments in: 'jll'!Checking ================= Compiler warnings: ================= &integerObject[]->backdoor.insert (*) ***** A run-time qualification check will be generated here -------------------------------------------- No. of warnings: 1 !Code generation Linking Object program on file: jll >>..... >Karl >~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > Karl Waclawek > KD Soft Inc. > * Phone: (905) 579-3443 > * E-Mail: waclawek@idirect.com