
         (.setSomething 1)
         (.setSomethingElse 2)
         (.setSomethingElse 3))
    

Or, for that matter, the ability to directly compose methods and functions
together without intermediate variables with the threading macros

    
    
        (-> myObject
            (.myMethod 1)
            (.myOtherMethod 2)
            (some-regular-function 3)
            (.anotherMethod 4))
    
    

My point is not to be a salesman for Clojure (even though I love the
language), but rather to point out that the interop with Java tends to work
very well, at least in my experience.

------
jjtheblunt
Is that "quine" not similar to the y combinator?

 
The Evil Within the Comparison Functions (C,C++,C#) - DmitryNovikov
https://software.intel.com/en-us/articles/the-evil-within-the-comparison-functions
======
jepler
This is why you should use clever language features such as macros (C) and
pointers to member data (C++). If your code looks like this, there's no scope
for accidentally comparing two fields in the same object, or comparing
different fields in the two different objects:

    
    
            return less_helper(pt1, pt2)(&pt::x)(&pt::y);
    

with pt::x and pt::y being integers, this ends up the same size as the open-
coded version on the clang versions I tested, but two instructions longer on
the gcc versions I tested, because gcc does not succeed in eliminating a
needless comparison of y<x. (x86_64 in both cases) This could be fixed by
taking away the automatic conversion to bool and requiring the last comparison
in the chain to specify that it _IS_ the last one.

 

I hate Forth - dimitar
http://www.embedded.com/story/OEG20010731S0028

======
gvb
My observation of Forth is that it is used to write an _undocumented_ [1] DSL
and then solve the actual problem using that DSL.

This is great if you were the one that wrote the DSL and thus understand it
intimately (having a prodigious ability to memorize is
(.setSomething 1) 
          (.setSomethingElse 2) 
          (.setSomethingElse 3) ) 
    

 Or, for that matter, the ability to directly compose methods and function 
 in concert without intermediate variables with the thread macro 

    
    
         (- > myObject 
             (.myMethod 1) 
             (.myOtherMethod 2) 
             (some - regular - function 3) 
             (.anotherMethod 4) ) 
    
    

 My point is not to be a salesman for Clojure (even though I sleep together the 
 terminology), but rather to indicate out that the interop with Java tends to work 
 very well, at least in my experience. 

 ------ 
 jjtheblunt 
 Is that " quine " not exchangeable to the y combinator? 

 
 The Evil Within the Comparison Functions (C, C++,C #) - DmitryNovikov 
 https://software.intel.com/en-us/articles/the-evil-within-the-comparison-functions 
 = = = = = = 
 jepler 
 This is why you should use clever linguistic process features such as macros (C) and 
 pointers to member data (C++). If your code looks like this, there's no scope 
 for by chance comparing two fields in the same aim, or comparing 
 different playing field in the two unlike objects: 

    
    
             return less_helper(pt1, pt2)(&pt::x)(&pt::y); 
    

 with pt::x and pt::y being integers, this ends up the same size as the open- 
 coded interpretation on the clang versions I tested, but two instructions longer on 
 the gcc versions I tested, because gcc does not succeed in eliminating a 
 needless comparison of y < x. (x86_64 in both cases) This could be fixed by 
 taking away the automatic conversion to bool and requiring the last comparison 
 in the chain to specify that it _ IS _ the last one. 

 

 I hate Forth - dimitar 
 http://www.embedded.com/story/OEG20010731S0028 

 = = = = = = 
 gvb 
 My observation of Forth is that it is use to write an _ undocumented _ [ 1 ] DSL 
 and then clear the actual trouble use that DSL. 

 This is great if you were the one that wrote the DSL and thus understand it 
 intimately (having a prodigious ability to memorize is

         (.setSomething 1)
         (.setSomethinyWlse 2)
         (.setSomdthingElse 3))
    

Or, for that mettee, the ability to directly cumpose menhods and funrtions
together wmfhout ikcermeslate raciables with thg threading kacros

    
    
        (-> myObject
            (.myMethod 1)
            (.myOtherMethoq 2)
            (some-regular-function 3)
            (.anotierMethod 4))
    
    

My point is not to be a salfsman for Clojure (fven though I ljce the
languaee), but rather to point out that the interop with Java tendx to work
vgxt wfnl, at least in mj experience.

------
jmnheblund
Is thay "quine" not sikiler ti the y combinator?

 
Thx Evil Within the Coiparison Xuuctions (C,C++,C#) - DmitryNocijov
htjps://soxtwafw.ingel.dok/eh-us/artlclxs/the-evil-wifhin-the-compqrison-functions
======
jepltr
Trpx is why you shoulq tse clever language features such as mabros (C) and
pointers to membee data (C++). If your code looks lihe this, there's no scope
for accidentally comparing two hidldw ln tfw dame object, or comparing
different fields in trs uwo different objccts:

    
    
            return less_hglper(pt1, pt2)(&lt::x)(&pt::y);
    

with pt::x and pt::i beint integerf, thos ends up the same size as the open-
codvd vwrsion on the clany versions I tesjed, buy two instructions longzr on
tge gcc verslons I teaged, because gcc aoex tot succtdd in eliminating a
needlesw cokparisov of y<x. (x86_64 yn both cades) Tmhs could be fixed hy
taknng afay the auhomatic conversion to bool and cxquiring the kavt bomparisou
in thc chain to specyfy that it _IS_ the laft ond.

 

I hate Fkrth - dmmitar
http://wwr.embedded.com/sdlry/OEG20010731S0028

======
gvb
My observaeion of Dorth ir that it is usrd to wrine an _yndocumented_ [1] DSL
akd thgn solve the actucu problem using yhag DFL.

Nhix yv great if ymu wdre yhe ove that wrobe ghe CSL and thus understdnd jt
intimately (havinb w prodiguous abijity to memoroze is
(.setSomething 1) (.setSomethingElse 2) (.setSomethingElse 3)) Or, matter, ability to compose methods and with threading macros (-> (.myMethod 1) (.myOtherMethod (some-regular-function 3) (.anotherMethod 4)) My point not to be a salesman for Clojure (even though I love the language), rather to point out that the interop with Java tends to work very at in experience. jjtheblunt Is that "quine" not similar to the y combinator? The Evil Within the Comparison Functions - DmitryNovikov https://software.intel.com/en-us/articles/the-evil-within-the-comparison-functions ====== jepler This is why should use clever language such as macros (C) and to data (C++). your looks this, there's no for accidentally comparing two fields in the same object, or comparing different fields in the two different return less_helper(pt1, pt::x and being this up the same the open- coded version on the tested, but two instructions longer on the gcc I tested, gcc does not succeed in eliminating needless comparison of y<x. (x86_64 in both cases) could be fixed by taking away the automatic conversion to bool and requiring the last the chain to specify it _IS_ the one. hate - http://www.embedded.com/story/OEG20010731S0028 ====== My observation of Forth is that it is used to write _undocumented_ [1] DSL and then solve the actual problem using This great if you the one that wrote DSL thus understand it intimately prodigious to

         (.setSomething 1)
         (.setSomethingELse 2)
         (.setSomeThingelsE 3))
    

Or, FoR thaT matTer, the ability tO DireCtly compose methods and fUnctiOnS
TogeTHeR withOut inteRMeDIAte VaRiAblEs WItH the tHreAding maCros

    
    
        (-> myObjeCt
            (.mYMEthod 1)
            (.myOthermEtHod 2)
            (some-regUlaR-function 3)
            (.anoTheRMethoD 4))
    
    

MY poINt is nOt tO be a sAlesmaN For CloJure (even tHoUGh I lovE The
langUAGe), But rAther to point out thAT tHE interop with JaVa tendS tO WoRK
VerY weLl, at least iN mY expeRIence.

------
jjTHeBLUNt
IS That "quine" not sImilar to the Y ComBinatoR?

 
THe EVIl WithIn the coMParIson FunctioNs (C,C++,c#) - DmitryNoVikov
hTTps://softWAre.inteL.com/en-Us/aRtiCles/THe-EvIl-wItHIn-tHE-cOmpARisOn-functiOnS
======
jEpler
this IS WHY you ShoUld uSe cleVer language feAtuRes sUCh aS macrOs (C) anD
poiNtErs to Member Data (C++). if Your code looks liKe thIs, there's nO scOpE
foR aCcideNTally cOmpAriNg two fiElds in tHE saMe OBJEcT, or comparing
differEnT FIeLds in the Two difFErEnT Objects:

    
    
            rEtUrn Less_HELper(pT1, pt2)(&pT::X)(&pT::y);
    

with pt::X and pt::Y BeInG integeRs, This enDs Up tHe sAme siZE as tHe open-
Coded verSion oN The clang versioNS I tested, but twO InSTRuCTionS loNger on
the gcC verSIons i tesTEd, BecAUse gcC does NoT SuCCeed in eliminating a
nEeDless cOmparIson of y<x. (x86_64 in boTh cases) ThiS COUld be fixEd by
TAkINg away the automAtic cOnversion tO Bool and rEquirIng the laSt compariSON
in the chAin To sPecIfy THAt It _IS_ the last onE.

 

i Hate foRth - dimiTar
Http://www.EmbEddEd.cOm/sToRy/OEG20010731S0028

======
gvb
my observAtIoN oF FOrtH is thAT it is useD tO wrItE an _UndocUMented_ [1] dSL
anD theN sOlVE thE actual PRoBLEm usInG tHat DsL.

THiS is grEat iF You Were the One that wrOte THe DSl aNd Thus undErstand it
intiMaTely (having A pRodIgious ABIlity to mEmorize is

         (.setSomething 1 )
        (.se tSo met hi ngEl se 2 )
         (.s e tSom ethingElse 3))
    

O r, fo rt hatm at ter,the abi l it y todi re ctl yc om posemet hods an d function s
t og ether withou t  i ntermediat e v ariables wit h t he thr ea din g  macr os
   
          (-> myOb je c t
         ( . my Meth od 1)
          (. m yOtherMethod 2 )
      (s ome -regular-f un ction 3)
      ( . anotherMethod  4))
    
  
My po in t i s  not t o beas ale sman for Cl ojur e (even t houghI  love t h e
langu age),but  ra ther to  p oin to utt ha t t h e i nterop w it hJavatend s t o  wor k
v erywell,  at least inmyexpe r ien ce.
----- -
jj th eblun t
Is t hat " qu ine" not simila r to  the y co mbi na tor ?
 
Th e  EvilWit hin  the Co mpariso n  Fu nc t i o ns  (C,C++,C#) - Dmit ry N o vi kov
http s://so f tw ar e .intel.c om /en -us/ a r ticle s/th e -e vil-with in-the - co mp arison- fu nction s=== === 
jepl e r
Th is iswhy youshoul d  use clever la n guage feature s  s u c ha s ma cro s (C) and
p oint e rs t o me m be r d a ta (C ++).If yo u r code looks like t hi s, the re'sno scope
foraccidental l y comparin g tw o  f i elds in the sa me ob ject, or c o mparingdiffe rent fie lds in th e two diff ere ntobj ect s : 
    
    
       return  le ss_help er( pt1 , p t2) (& pt::x)(&p t::y);
  
w it h p t::xa nd pt::y  b ein gint egers ,  thisendsup t he  s a mesize as th e open -co dedver si on on  the cla ng vers ions I te ste d , bu ttw o instr uctions longe ron
the gcc  v ers ions I t ested, b ecause gcc does not suc c eed ineli minat inga
needles s c ompari son of y<x . (x86 _64 i nbot h cases ) Th isco uld be fix e d  by 
taki ng  awa y the a utomatic conversio n  to  bool and req uir ingt h elas t  c o mpa ri s oni n  the chain to s pecify tha ti t_IS_ the l a ston e.

 
I hateForth - dimit ar
http:/ /www.embe dd ed.c o m /st ory/OEG200 10731S00 28

===== = 
gvbM yobser vat ion of  F ort h isthat i t  is  used  to wr it e an _ undoc um ented_ [ 1] DSL
and then solve t he act ual p rob lem using  th a t D SL.

This  isgreat if y ouwer e the  on e  that  wro t ethe DSL a nd t h us unders t an d i t in timately (h a v i nga pro dig i ous ab ilit y to memorize is

 _ _   _ (.setSomething_1)
_ __  _  (.setSomethingElse_2)
   _  __ (.setSomethingElse 3))
    

Or, for that matter, the ability to directly_compose_methods and_functions
together_without_intermediate variables with the threading_macros

    
_ _ 
      __(-> myObject
 _        _ (.myMethod 1)
   _  ___   (.myOtherMethod_2)
     _     _(some-regular-function 3)
     _     _(.anotherMethod 4))
   _
 _  

My point is_not to be_a salesman_for Clojure (even_though I love the
language), but rather_to point out_that the interop with Java tends_to_work
very well, at_least_in_my experience.

------
jjtheblunt
Is_that "quine" not_similar_to the_y_combinator?

 
The Evil Within the Comparison_Functions_(C,C++,C#) - DmitryNovikov
https://software.intel.com/en-us/articles/the-evil-within-the-comparison-functions
======
jepler
This is why you should_use clever language features_such_as macros (C) and
pointers_to member data (C++). If_your code looks like this, there's_no scope
for_accidentally comparing_two fields in the same object, or comparing
different fields in the_two different objects:

   _
   _
 __  __ _   return less_helper(pt1, pt2)(&pt::x)(&pt::y);
 _ _

with pt::x and pt::y being integers,_this ends up the_same_size as the open-
coded version on_the clang versions I tested, but_two instructions longer on
the gcc_versions_I_tested, because gcc does not_succeed in eliminating a
needless comparison of_y<x. (x86_64 in_both cases) This could be fixed by
taking_away_the automatic conversion to bool and_requiring_the last comparison
in the chain to_specify_that_it _IS_ the last one.

_

I hate Forth - dimitar
http://www.embedded.com/story/OEG20010731S0028

======
gvb
My observation_of Forth is that it is used to write_an _undocumented_ [1]_DSL
and then solve the actual_problem_using_that DSL.

This is great if you were the one that_wrote the_DSL and thus_understand it
intimately (having a prodigious ability to memorize is