jackdaniel changed the topic of #lisp to: Common Lisp, the #1=(programmable . #1#) programming language | <https://irclog.tymoon.eu/freenode/%23lisp> <https://irclog.whitequark.org/lisp> <http://ccl.clozure.com/irc-logs/lisp/> | offtopic --> #lispcafe
yitzi has quit [Quit: yitzi]
nckx is now known as PotentialUser-93
PotentialUser-93 is now known as nckx
cjb has joined #lisp
stoneglass has quit [Quit: stoneglass]
troydm has joined #lisp
wxie has joined #lisp
dra_ has quit [Quit: Leaving]
cjb has quit [Ping timeout: 252 seconds]
cjb has joined #lisp
nicktick has joined #lisp
yitzi has joined #lisp
johnjay has joined #lisp
ralt has quit [Quit: Connection closed for inactivity]
orivej has quit [Ping timeout: 264 seconds]
wxie has quit [Ping timeout: 264 seconds]
prite has joined #lisp
prite has quit [Client Quit]
prite has joined #lisp
prite has quit [Client Quit]
vutral has joined #lisp
_jrjsmrtn has joined #lisp
prite has joined #lisp
prite has left #lisp [#lisp]
__jrjsmrtn__ has quit [Ping timeout: 265 seconds]
rumbler31_ has joined #lisp
Jesin has quit [Ping timeout: 260 seconds]
wxie has joined #lisp
bsd4me has quit [Remote host closed the connection]
space_otter has joined #lisp
yitzi has quit [Quit: yitzi]
torbo has joined #lisp
wxie has quit [Ping timeout: 260 seconds]
jufearcas has quit [Ping timeout: 240 seconds]
libertyprime has joined #lisp
Bike has quit [Quit: Lost terminal]
libertyprime has quit [Ping timeout: 264 seconds]
libertyprime has joined #lisp
specbot has quit [Remote host closed the connection]
stepnem has quit [Ping timeout: 265 seconds]
specbot has joined #lisp
kapilp has joined #lisp
stepnem has joined #lisp
minion has quit [Disconnected by services]
Oladon has joined #lisp
minion has joined #lisp
libertyprime has quit [Ping timeout: 260 seconds]
kapil_ has quit [Ping timeout: 265 seconds]
vsync has quit [Ping timeout: 265 seconds]
APic has quit [Ping timeout: 265 seconds]
alandipert2 has joined #lisp
libertyprime has joined #lisp
cjb has quit [Ping timeout: 272 seconds]
vaporatorius__ has quit [Ping timeout: 265 seconds]
pfr has quit [Ping timeout: 265 seconds]
alandipert has quit [Ping timeout: 265 seconds]
ult has quit [Ping timeout: 265 seconds]
davsebamse has quit [Ping timeout: 265 seconds]
cods has quit [Ping timeout: 265 seconds]
alandipert2 is now known as alandipert
mangoicedtea has quit [Read error: Connection reset by peer]
dddddd_ has quit [Ping timeout: 265 seconds]
matijja has quit [Ping timeout: 265 seconds]
dim has quit [Ping timeout: 265 seconds]
ferada has quit [Ping timeout: 265 seconds]
Ziemas has quit [Ping timeout: 265 seconds]
matijja has joined #lisp
ult has joined #lisp
pfr has joined #lisp
vsync has joined #lisp
noguchitan has joined #lisp
dim has joined #lisp
grumble has quit [Ping timeout: 619 seconds]
cjb has joined #lisp
cods has joined #lisp
Ziemas has joined #lisp
grumble has joined #lisp
rumbler31_ has quit [Ping timeout: 256 seconds]
APic has joined #lisp
rumbler31 has joined #lisp
ferada has joined #lisp
vaporatorius__ has joined #lisp
cjb has quit [Ping timeout: 272 seconds]
dddddd_ has joined #lisp
davsebamse has joined #lisp
cjb has joined #lisp
arpunk has joined #lisp
cjb has quit [Remote host closed the connection]
rumbler31 has quit [Remote host closed the connection]
jesse1010 has quit [Ping timeout: 240 seconds]
grobe0ba has quit [Ping timeout: 256 seconds]
grobe0ba has joined #lisp
dyelar has quit [Quit: Leaving.]
bsd4me has joined #lisp
bsd4me has left #lisp ["Leaving"]
jufearcas has joined #lisp
libertyprime has quit [Ping timeout: 264 seconds]
mindCrime has quit [Ping timeout: 244 seconds]
libertyprime has joined #lisp
rumbler31 has joined #lisp
panji has joined #lisp
<panji> Is it a bug for ABCL or implementation-dependent for TYPE-ERROR-EXPECTED-TYPE? https://gist.github.com/epanji/48507968d74a3355e59ef9c544fda93e
* panji will check log when someone answer it later
jufearcas has quit [Ping timeout: 246 seconds]
Necktwi has quit [Ping timeout: 264 seconds]
libertyprime has quit [Ping timeout: 256 seconds]
panji has left #lisp [#lisp]
libertyprime has joined #lisp
<beach> Good morning everyone!
Necktwi has joined #lisp
torbo has quit [Remote host closed the connection]
_paul0 has joined #lisp
paul0 has quit [Ping timeout: 272 seconds]
gravicappa has joined #lisp
Lord_of_Life_ has joined #lisp
johnjay has quit [Ping timeout: 264 seconds]
Lord_of_Life has quit [Ping timeout: 264 seconds]
Lord_of_Life_ is now known as Lord_of_Life
johnjay has joined #lisp
gravicappa has quit [Ping timeout: 240 seconds]
shangul has joined #lisp
shifty has quit [Ping timeout: 246 seconds]
vutral has quit [Quit: Connection closed for inactivity]
igemnace has joined #lisp
karlosz has quit [Quit: karlosz]
epony has quit [Ping timeout: 258 seconds]
shka_ has joined #lisp
johnjay has quit [Ping timeout: 256 seconds]
hipete has quit [Ping timeout: 240 seconds]
johnjay has joined #lisp
epony has joined #lisp
elflng has quit [Read error: Connection reset by peer]
elflng has joined #lisp
libertyprime has quit [Ping timeout: 265 seconds]
krid` has quit [Ping timeout: 256 seconds]
libertyprime has joined #lisp
bocaneri has joined #lisp
Oladon has quit [Quit: Leaving.]
libertyprime has quit [Ping timeout: 240 seconds]
libertyprime has joined #lisp
jibanes has quit [Ping timeout: 260 seconds]
nullman has quit [Ping timeout: 260 seconds]
rippa has joined #lisp
jibanes has joined #lisp
nullman has joined #lisp
panji has joined #lisp
<panji> hello
libertyprime has quit [Ping timeout: 260 seconds]
<beach> Hello panji.
libertyprime has joined #lisp
<panji> beach: hi, any answer for my question above?
libertyprime has quit [Client Quit]
<beach> I can't quite parse your question, but it looks like a bug in ABCL.
<beach> Oh wait...
johnjay has quit [Ping timeout: 256 seconds]
<beach> You are calling expected-type with a symbol.
<beach> OK, so then you call SYMBOL-FUNCTION with that symbol.
<panji> i want to know argument type for function created by defstruct.
<beach> What is the argument type for a function?
<panji> (foo-a arg) the arg.
<beach> You can supply any argument to a function.
<beach> It may result in an error being signaled, of course.
<panji> i expect too get foo from my example
<beach> You call the function on NIL.
<panji> yes
<beach> So, then what you want is a type-error to be signaled because NIL is not of the right type. Is that a correct interpretation?
<beach> I am sorry, but I am a very slow thinker, so you need to be very explicit.
<panji> in my example FOO-A have one argument, and it is STRUCTURE-OBJECT FOO. in ABCL i get STRUCTURE-OBJECT instead of FOO.
<beach> So, you are expecting ABCL to signal an error because the argument to FOO-A is not of the right type?
johnjay has joined #lisp
<panji> No, i want ABCL function TYPE-ERROR-EXPECTED-TYPE return FOO
<panji> It is like returning NUMBER instead of INTEGER.
<phoe> O dpm
<phoe> sorry
<phoe> I don't understand that code
<beach> panji: But in order for type-error-expected-type to be called, the call to FUNCALL must signal an error, right?
<phoe> you're calling FOO-A with NIL as an argument
<beach> *sigh*
<beach> panji: It looks like phoe is going to sort this out for you. He is a much quicker thinker than I am.
<panji> Yes, so i handle that in handler-case.
<phoe> beach: it is also too early for me, sorry
<panji> phoe: yes, with nil.
<beach> panji: So then, you rely on the fact that ABCL will signal an error.
<panji> beach: yes.
<phoe> that TYPECASE makes no sense because a) symbols are funcallable, b) the T case is erroneous because NIL is not fbound
<beach> panji: But where does it say that calling a slot accessor with the wrong type must signal an error?
<panji> beach: i don't know.
<phoe> much simpler testcase: (defstruct foo a) (handler-case (foo-a nil) (type-error (e) (type-error-expected-type e)))
<beach> panji: Well, you need to check that first before relying on that behavior.
<phoe> and you'd like that to return FOO instead of STRUCTURE-OBJECT
shifty has joined #lisp
<phoe> if I understand that correctly
<panji> phoe: correct
<beach> phoe: The assumption is that an error must be signaled when a slot accessor is called with the wrong type.
<beach> But I'll shut up now. Too much noise.
<phoe> panji: basically, what beach said - the standard does *not* guarantee that a TYPE-ERROR will always be signaled
<phoe> it seems like ACL signals a SIMPLE-ERROR where as SBCL/CCL/ECL/CLISP/LW/ABCL signal a TYPE-ERROR
<panji> phoe: So, it is mean implementation-dependent?
<phoe> yes, it seems so
<phoe> but of all the implementations that signal TYPE-ERRORs, only ABCL does not return FOO as the TYPE-ERROR-EXPECTED-TYPE
<phoe> which also seems invalid for me because FOO-A is *not* going to work on all structure objects, only on FOOs
<phoe> so if ABCL decides to go this way, then it should go this way all the way\
<phoe> like, if it signals a TYPE-ERROR, it might as well signal a correct one
<phoe> that is one thing
<beach> panji: Either way, I highly recommend you not use structs. It is a much better idea to use standard classes.
jeosol has quit [Ping timeout: 245 seconds]
<phoe> the other thing is how the consequences of calling (FOO-A NIL) are defined in the specification
<panji> beach: Yes, i prefer use standard class too. But i am experimenting this https://github.com/epanji/generic-structure-reader/
<beach> phoe: It looks to me like undefined behavior. There is nothing in the "Exceptional situations" section about it.
<panji> and i have told by _death not too use it long time ago. :)
<beach> phoe: So it looks to me like it is one of those cases of default undefined behavior that the standard invokes.
<phoe> beach: seems the same to me
<phoe> if you call FOO-A with anything that is not FOO then the implementation is allowed to get creative with what it does
<phoe> so you cannot count on a TYPE-ERROR
<beach> Note to self: In WSCL, specify the consequences of calling a struct slot accessor with the wrong type.
<panji> Thanks phoe, beach. It's clear out some problem in my head.
<beach> Sure. Sorry for being so dense.
<phoe> oh, right
<phoe> (defstruct bar b) (foo-a (make-bar :b 42))
<phoe> ;=> 42
<phoe> that is on ABCL, and that is allowed
<phoe> and that is because signaling errors may *NOT* happen at all in case of structure accessors
<phoe> so, basically
<phoe> if you depend on errors, you don't want to use Lisp structs - go for classes instead
<phoe> and for classes, generic-structure-reader is unnecessary
<phoe> so I'll join _death and tell you not to use that :D
<panji> :)
<phoe> also, I see why ABCL returns STRUCTURE-OBJECT as a type in there now
<phoe> it seems that structs are implemented as Java arrays of LispObjects under the hood, and each struct accessor calls a simple array access.
<phoe> which means that structure accessors are interchangeable, which is why every other structure will do, too.
<phoe> .....as long as there is no ArrayIndexOutOfBounds along the way, which seems to cause an internal error in ABCL...
gravicappa has joined #lisp
shifty has quit [Ping timeout: 246 seconds]
panji has quit [Ping timeout: 260 seconds]
space_otter has quit [Remote host closed the connection]
shifty has joined #lisp
<beach> And maybe NIL is a struct?
<beach> Or, rather, just a Java array.
jgodbout has quit [Ping timeout: 265 seconds]
<phoe> nope, it's a bit more complex than that
shifty has quit [Ping timeout: 256 seconds]
<phoe> ABCL explicitly expects a STRUCTURE-OBJECT, which NIL is not
<beach> OK.
<phoe> but once it gets a STRUCTURE-OBJECT, anything seems to go
Aurora_v_kosmose has quit [Quit: brb]
nullman has quit [Ping timeout: 265 seconds]
Aurora_v_kosmose has joined #lisp
jonatack has quit [Ping timeout: 260 seconds]
Aurora_v_kosmose has quit [Remote host closed the connection]
scymtym has quit [Ping timeout: 240 seconds]
Aurora_v_kosmose has joined #lisp
okflo has quit [Remote host closed the connection]
hipete has joined #lisp
scymtym has joined #lisp
whiteline has joined #lisp
arduo has joined #lisp
gaqwas has joined #lisp
nullman has joined #lisp
pve has joined #lisp
scymtym has quit [Remote host closed the connection]
heisig has joined #lisp
gal has quit [Ping timeout: 272 seconds]
hendursa1 has joined #lisp
hendursaga has quit [Ping timeout: 240 seconds]
VincentVega has joined #lisp
<VincentVega> Guys, how do I morph a symbol into a property aka sym -> :sym? Also, is there a utility for prefixing/postfixing symbols?
<beach> VincentVega: There is no such thing as a "property" in Common Lisp.
<beach> So do you want to create a keyword symbol that has the same name as a non-keyword symbol?
<VincentVega> beach: yes
<phoe> VincentVega: Alexandria has got you covered
<phoe> (alexandria:make-keyword 'foo) ;=> :FOO
<beach> VincentVega: And what do you mean by prefixing/postfixing symbols?
<VincentVega> phoe: oh, awesome
<phoe> (let ((*package* (find-package :keyword))) (alexandria:symbolicate 'foo 'bar)) ;=> :FOOBAR
<phoe> also, s/property/keyword/
<VincentVega> beach: like (prefix sym 'pre) -> 'pre-sym
<phoe> keywords have much more use in CL than just "properties", whatever that means
<VincentVega> phoe: sorry, I meant keywords
<beach> VincentVega: First of all, that would not return something that is quoted.
<phoe> <3
<VincentVega> phoe: thanks for the links
<beach> VincentVega: Second, why would you want to prefix/suffix symbols?
<beach> There is not much use for that.
<phoe> in particular, (let ((*package* (find-package :keyword))) (alexandria:symbolicate "PRE-" 'bar))
<phoe> ;=> :PRE-BAR
<phoe> that's useful for macro writing, I guess.
<VincentVega> phoe: nice, thanks man
<phoe> which is a niche, but still
<VincentVega> beach: I needed it for some macros
<beach> VincentVega: Can you be more specific?
<beach> VincentVega: It is usually a bad idea for macros to create symbols other than symbols created by GENSYM.
<VincentVega> beach: My macro generates a class and a structure. The structure has the same name as the class, but postfixed -data.
<beach> Sounds fishy to me, but yes, I see.
<phoe> why though
<phoe> you have slots for that
<phoe> why do you need another layer of indirection?
<VincentVega> phoe: beach: So, what I do is my class contains a description of values to be checked (such as ranges of values, various properties) from which description I later initialize multiple instances of the structure.
<beach> Sounds like a use case for a metaclass.
<VincentVega> beach: It is? I should read up on those then.
<VincentVega> thanks for the pointer
<beach> Well, it looks like your structures are sort of like instances of an instance of your class.
<beach> I am assuming you didn't mean that the class itself contains the description of values, but that an instance of that class does.
<beach> So if you turn your class into a metaclass, your class instance into a class, and your structures into instances of that class, it should do the same trick.
<VincentVega> Sounds like good deal to me.
<VincentVega> Yeah, definitely sounds neat, will try to figure this out, thanks again.
<beach> Sure. Good luck.
ralt has joined #lisp
camlriot42 has quit [Quit: Idle for 30+ days]
orivej has joined #lisp
ukari has joined #lisp
ukari has quit [Remote host closed the connection]
shifty has joined #lisp
EvW has joined #lisp
nullman has quit [Ping timeout: 240 seconds]
ljavorsk has joined #lisp
hipete has quit [Ping timeout: 256 seconds]
_whitelogger has joined #lisp
jesse1010 has joined #lisp
nullman has joined #lisp
scymtym has joined #lisp
jonatack has joined #lisp
Posterdati has joined #lisp
nicktick has quit [Ping timeout: 240 seconds]
Necktwi has quit [Ping timeout: 272 seconds]
VincentVega has quit [Remote host closed the connection]
dra_ has joined #lisp
dra_ is now known as dra
<dra> Hello!
<phoe> heyyy
<dra> I recently came across a Lisp dialect that doesn't use S-expr notation for its code. Any idea what the dialect is called?
<phoe> you mean Dylan?
<beach> dra: There is no consensus as to what constitutes a "Lisp dialect".
<phoe> that's the closest match my memory has to "Lisp without sexprs"
<beach> dra: However, initially, Lisp was supposed to use M-notation.
v3ga has quit [Read error: Connection reset by peer]
<jdz> The programmatically-generated monospace font I use (Iosevka) is written one such dialect, but I don't remember what it's called.
v3ga has joined #lisp
<dra> beach: Yes, sure. It looked rather like M-exprs.
<beach> dra: It could be many things. We have regular visitors here who, for some reason, would like for their recently created language to be a "Lisp dialect". I don't know why, since Lisp is not particularly popular.
<beach> dra: But phoe is right. Dylan was meant to be a version of Scheme, and it was initially written with S-expressions. But then they changed it, presumably in the hopes of improving its acceptance.
<dra> beach: I can imagine. The reason I ask: The syntax reminded me of Anatomy of Lisp, which is similar to M-exprs. So I'd like to take a closer look but I forgot what language that was...
<beach> In fact, RScheme (by Paul Wilson and his group) is essentially Dylan using S-expressions.
<beach> dra: I see.
VincentVega has joined #lisp
Necktwi has joined #lisp
v3ga_ has joined #lisp
v3ga has quit [Ping timeout: 260 seconds]
<beach> Looks like something created for teaching purposes.
<dra> Yes. Complexity-wise it seems to be about the same as sl3.c.
wxie has joined #lisp
dddddd_ is now known as dddddd
shifty has quit [Ping timeout: 240 seconds]
Cymew has joined #lisp
Bourne has joined #lisp
Bourne has quit [Ping timeout: 240 seconds]
yitzi has quit [Quit: yitzi]
random-nick has joined #lisp
wxie has quit [Ping timeout: 264 seconds]
wxie has joined #lisp
EvW has quit [Ping timeout: 240 seconds]
simplegauss has quit [Ping timeout: 260 seconds]
gargaml has joined #lisp
sveit has quit [Ping timeout: 260 seconds]
bitmapper has quit [Ping timeout: 240 seconds]
sveit has joined #lisp
simplegauss has joined #lisp
wxie has quit [Ping timeout: 240 seconds]
gal has joined #lisp
EvW has joined #lisp
ggole has joined #lisp
rumbler31 has quit [Ping timeout: 256 seconds]
rumbler31 has joined #lisp
rumbler31 has quit [Ping timeout: 260 seconds]
yitzi has joined #lisp
shangul has quit [Ping timeout: 256 seconds]
nicktick has joined #lisp
Necktwi has quit [Ping timeout: 240 seconds]
Bike has joined #lisp
Z10N has joined #lisp
igemnace has quit [Remote host closed the connection]
ljavorsk has quit [Ping timeout: 265 seconds]
Z10N is now known as ZION
ZION is now known as Z10N
Z10N has quit [Ping timeout: 260 seconds]
whiteline has quit [Remote host closed the connection]
whiteline has joined #lisp
Necktwi has joined #lisp
krid` has joined #lisp
dra has quit [Quit: Leaving]
wsinatra has joined #lisp
hendursa1 has quit [Quit: hendursa1]
hendursaga has joined #lisp
<phoe> Online Lisp Meeting #7 announced
shangul has joined #lisp
arpunk has quit [Read error: Connection reset by peer]
wsinatra has quit [Client Quit]
random-nick has quit [Ping timeout: 265 seconds]
EvW has quit [Ping timeout: 264 seconds]
wsinatra has joined #lisp
random-nick has joined #lisp
VincentVega has quit [Remote host closed the connection]
wxie has joined #lisp
Bourne has joined #lisp
gaqwas has quit [Remote host closed the connection]
gko_ has joined #lisp
lucasb has joined #lisp
gaqwas has joined #lisp
gaqwas has quit [Changing host]
gaqwas has joined #lisp
wxie has quit [Ping timeout: 256 seconds]
orivej has quit [Ping timeout: 265 seconds]
pve has quit [Ping timeout: 256 seconds]
pve has joined #lisp
cosimone has joined #lisp
pve has quit [Ping timeout: 256 seconds]
gaqwas has quit [Remote host closed the connection]
pve has joined #lisp
mangul has joined #lisp
shangul has quit [Ping timeout: 240 seconds]
gaqwas has joined #lisp
gaqwas has quit [Changing host]
gaqwas has joined #lisp
pve has quit [Ping timeout: 265 seconds]
pve has joined #lisp
vgmind has joined #lisp
vgmind has quit [Quit: Leaving]
vgmind has joined #lisp
zooey_ has quit [Remote host closed the connection]
zooey has joined #lisp
jw4 has quit [Read error: Connection reset by peer]
tutti has joined #lisp
EvW1 has joined #lisp
jw4 has joined #lisp
orivej has joined #lisp
radikal has quit [Quit: leaving]
EvW1 has quit [Ping timeout: 260 seconds]
krid` has quit [Ping timeout: 240 seconds]
gaqwas has quit [Remote host closed the connection]
gaqwas has joined #lisp
gaqwas has quit [Changing host]
gaqwas has joined #lisp
heisig has quit [Quit: Leaving]
EvW has joined #lisp
bsd4me has joined #lisp
bitmapper has joined #lisp
krid` has joined #lisp
dyelar has joined #lisp
karlosz has joined #lisp
smazga has joined #lisp
gko_ has quit [Ping timeout: 240 seconds]
dra has joined #lisp
<jmercouris> anyone have experience putting license headers at the top of lisp files?
<jmercouris> double semicolon? triple? quadruple?
<Bike> clhs 2.4.4.2
<specbot> Notes about Style for Semicolon: http://www.lispworks.com/reference/HyperSpec/Body/02_ddb.htm
<phoe> clhs 2.4.4.2
<specbot> Notes about Style for Semicolon: http://www.lispworks.com/reference/HyperSpec/Body/02_ddb.htm
<Bike> i don't know why this is in the standard, but it is
<phoe> aaaaaa Bike was faster
<phoe> tl;dr four semicolons for headers
mindCrime has joined #lisp
<jmercouris> OK, so four
<jmercouris> and how shall I include the BSD license at the top? the whole body of the license?
<Bike> i'm used to seeing a quick summary, "look at license.txt", and the no-warranty
<phoe> do you have a requirement to add license information in every file?
<jmercouris> I do have such a requirement yes
<jmercouris> otherwise I would not do it
noguchitan has quit [Quit: WeeChat 2.3]
<jmercouris> I would think it would be sufficient to have a license file myself
<phoe> then what Bike said - licensed under MIT, comes with no warranty, see toplevel LICENSE.md for details
<jmercouris> great, thank you
gaqwas has quit [Remote host closed the connection]
EvW has quit [Ping timeout: 244 seconds]
pve has quit [Ping timeout: 265 seconds]
nicktick has quit [Ping timeout: 265 seconds]
vutral has joined #lisp
orivej has quit [Ping timeout: 256 seconds]
luckless_ has quit [Ping timeout: 240 seconds]
orivej has joined #lisp
luckless_ has joined #lisp
Lord_of_Life has quit [Ping timeout: 256 seconds]
Lord_of_Life has joined #lisp
orivej has quit [Ping timeout: 264 seconds]
gabiruh has quit [Quit: ZNC 1.7.5 - https://znc.in]
mangul has quit [Ping timeout: 256 seconds]
vgmind has quit [Remote host closed the connection]
gabiruh has joined #lisp
gal is now known as galex-713
rogersm has joined #lisp
hipete has joined #lisp
stepnem has quit [Ping timeout: 240 seconds]
Bourne has quit [Ping timeout: 256 seconds]
stepnem has joined #lisp
dra has quit [Quit: Leaving]
<jasom> historic question: any reason that LOOP doesn't treat any compound form as implicitly having a "DO" before it?
Bourne has joined #lisp
<jmercouris> can you give an example ?
<jmercouris> also what is a “compound form”?
<Bike> a form that's a cons
<jmercouris> I see
<Bike> forms that are symbols would be hard to distinguish from loop syntax
<jmercouris> yes, that makes sense
<jmercouris> why would they want an implicit DO before them though?
<jmercouris> for example when you write UNTIL (xyz x)
<jmercouris> why would you want a DO before (xyz x)?
<Bike> i assume jasom meant compound forms that aren't part of some other loop syntax.
<Bike> so you could write (loop for i below 5 do (print i)) as (loop for i below 5 (print i))
<jmercouris> I see
<jmercouris> hm, probably for ease of parsing I would guess
<jmercouris> that can’t be it though
<jmercouris> are there any cases where it would be ambiguous?
<Bike> i don't think it would really complicate the parsing. if you enter this form now your implementation will probably say something like "compound form found where a loop keywords was expected"
<Bike> i think it would be confusing to me, though
<jmercouris> maybe the authors of loop had a preference for being explicit
ggole has quit [Quit: Leaving]
tutti has quit [Ping timeout: 272 seconds]
yitzi has quit [Quit: yitzi]
<_death> it has something close where you can add more than one compound form after DO...
shangul has joined #lisp
Th3D00D has joined #lisp
hipete has quit [Ping timeout: 264 seconds]
Cymew has quit [Ping timeout: 265 seconds]
ggoes has joined #lisp
rumbler31 has joined #lisp
nckx is now known as facebook
facebook is now known as nckx
rumbler31 has quit [Ping timeout: 246 seconds]
orivej has joined #lisp
bocaneri has quit [Remote host closed the connection]
gravicappa has quit [Ping timeout: 256 seconds]
cosimone has quit [Remote host closed the connection]
galex-713 has quit [Ping timeout: 272 seconds]
gal has joined #lisp
shangul has quit [Ping timeout: 240 seconds]
pfr has quit [Ping timeout: 256 seconds]
jgodbout has joined #lisp
mseddon has joined #lisp
mseddon has quit [Read error: Connection reset by peer]
rumbler31 has joined #lisp
EvW1 has joined #lisp
rogersm has quit [Quit: Leaving...]
hipete has joined #lisp
yitzi has joined #lisp
gaqwas has joined #lisp
gaqwas has quit [Changing host]
gaqwas has joined #lisp
scymtym has quit [Ping timeout: 244 seconds]
ralt has quit [Quit: Connection closed for inactivity]
shka_ has quit [Ping timeout: 260 seconds]
ralt has joined #lisp
wsinatra has quit [Quit: WeeChat 2.9]
vutral has quit [Quit: Connection closed for inactivity]
theBlackDragon has quit [Ping timeout: 264 seconds]
rumbler31 has quit [Remote host closed the connection]
EvW1 has quit [Ping timeout: 260 seconds]
theBlackDragon has joined #lisp
arduo has quit [Remote host closed the connection]
pfr has joined #lisp
rumbler31 has joined #lisp
Lycurgus has joined #lisp
Th3D00D has quit [Remote host closed the connection]
kaftejiman has joined #lisp
housel has joined #lisp
rogersm has joined #lisp
Lycurgus has quit [Remote host closed the connection]
shifty has joined #lisp
igemnace has joined #lisp
yonkunas has quit [Quit: Connection closed for inactivity]
terpri has quit [Ping timeout: 260 seconds]
Bourne has quit [Ping timeout: 265 seconds]
rogersm has quit [Quit: Leaving...]
gal has quit [Ping timeout: 272 seconds]
EvW has joined #lisp
gal has joined #lisp
<ralt> apparently I can't use (THE class ...)?
<_death> why not?
<ralt> I get a warning saying it's not valid
<_death> well, classes are types.. can you show the code/warning?
gal_ has joined #lisp
<aeth> I think it's because the class doesn't exist yet because it's defined in the same file
<aeth> Try moving it into another file or wrapping it in EVAL-WHEN
gal has quit [Ping timeout: 272 seconds]
<aeth> Alternatively, use CHECK-TYPE and move the check to strictly exist at runtime.
<aeth> THE/DECLARE might attempt some static checking even though there's no standardized behavior for what they do
<aeth> (Worst case scenario is that they *assume* the type!)
kaftejiman has quit [Remote host closed the connection]
gargaml has quit [Quit: WeeChat 2.9]
FennecCode has quit [Ping timeout: 244 seconds]
adam4567 has joined #lisp
jw4 has quit [Quit: tot siens]
jw4 has joined #lisp
cosimone has joined #lisp
morisama has joined #lisp
FennecCode has joined #lisp
rixard has quit [Read error: Connection reset by peer]
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
rixard has joined #lisp
dyelar has quit [Ping timeout: 244 seconds]
adam4567 has quit [Remote host closed the connection]
rumbler31 has quit [Ping timeout: 256 seconds]
torbo has joined #lisp
rumbler31 has joined #lisp
gaqwas has quit [Ping timeout: 265 seconds]
rumbler31 has quit [Ping timeout: 246 seconds]
dyelar has joined #lisp
rumbler31 has joined #lisp
<sveit> is it considered an SBCL bug (or is there a workaround?) that if i have a function F taking two arguments that may have unknown types, declaring it (ftype (function (t t)) F) compiles to (significantly) slower code with (using (optimize (speed 3) (safety 0))) than (ftype function F)?
<sveit> it seems that SBCL "stops" type inference if i put the "t"'s in place of arguments
<sveit> the reason this is frustrating is that my actual usecase is that sometimes i know the type of the first argument but not the second, so i would like to say (ftype (function (double-float t)) F), but this compiles to slower code than (ftype function F) (sorry for the long-winded examples)
terpri has joined #lisp
<aeth> sveit: I wonder if it permits * instead of t in the ftype, just like * in multi-dimensional arrays when you know some of the dimensions but not all, e.g. (2 *)
<Bike> f is like, an argument or a local variable or something, rather than a toplevel function?
cosimone has quit [Quit: Quit.]
<sveit> Bike: often f is an argument, yes
<Bike> hm... i'm not seeing any consistent slowdown... might be something there though
<sveit> aeth: i tried * instead of t, same problem
<Bike> in (defun foo (f x y) (declare (type (function (t t)) f) (optimize ...)) (funcall f x y))
<sveit> Bike: unfortunately i don't have a simple example, as far as I can tell it happens when functions (and definitions of the lambdas returned by them) are being inlined
igemnace has quit [Ping timeout: 272 seconds]
rumbler31 has quit [Remote host closed the connection]
<Bike> if it's a complex optimization issue, which is what it sounds like, maybe you should talk to #sbcl
<Bike> with some hopefully smallish example
Oladon has joined #lisp
mindCrime has quit [Excess Flood]
mindCrime has joined #lisp
adam4567 has joined #lisp
mangoicedtea has joined #lisp
igemnace has joined #lisp
scymtym has joined #lisp
random-nick has quit [Ping timeout: 260 seconds]
bonz060 has joined #lisp
bonz060 has quit [Client Quit]
bonz060 has joined #lisp
bonz060 has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
bonz060 has joined #lisp