Click here to Skip to main content
15,922,894 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
JokeRe: When is equal not equal? Pin
Peter_in_27806-May-19 2:26
professionalPeter_in_27806-May-19 2:26 
GeneralRe: When is equal not equal? Pin
honey the codewitch6-May-19 3:01
mvahoney the codewitch6-May-19 3:01 
GeneralRe: When is equal not equal? Pin
#realJSOP6-May-19 4:07
professional#realJSOP6-May-19 4:07 
GeneralRe: When is equal not equal? Pin
honey the codewitch6-May-19 4:53
mvahoney the codewitch6-May-19 4:53 
GeneralRe: When is equal not equal? Pin
#realJSOP6-May-19 5:05
professional#realJSOP6-May-19 5:05 
GeneralRe: When is equal not equal? Pin
honey the codewitch6-May-19 5:26
mvahoney the codewitch6-May-19 5:26 
GeneralRe: When is equal not equal? Pin
harold aptroot6-May-19 6:52
harold aptroot6-May-19 6:52 
GeneralRe: When is equal not equal? Pin
honey the codewitch6-May-19 7:26
mvahoney the codewitch6-May-19 7:26 
LOL. It's not a sum type.

It's ... hard to explain. It has to do with LALR and LL table generation, and the mechanics behind it.

I represent a CFG using a series of arbitrary symbols ids.

Users will probably only plug strings in here, but behind the scenes this CFG needs to be able to hold ints, and a special augmented symbol identifier <first#>ID<follows#>

However, as long as the user doesn't demand the impossible of the CFG they aren't limited to strings.

All that's required is an object to have identity equality semantics or at least be consistent in terms of refs it passes around and for the object to be able to get a hashcode off of it.

So object is okay here. There are caveats, but honestly, it was C#'s string optimization + a bug in my code that was causing me headaches. It all works fine now.

This is a *very* rare and very specific corner case for a very ugly/convoluted series of algorithms used to generate parsers.

So some rules will be bent. Others will be folded, spindled and otherwise mutilated.

So far I've never seen one even "readable" implementation of these algorithms, but mine is coming close.
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.

GeneralRe: When is equal not equal? Pin
Dr.Walt Fair, PE6-May-19 5:58
professionalDr.Walt Fair, PE6-May-19 5:58 
GeneralRe: When is equal not equal? Pin
honey the codewitch6-May-19 6:44
mvahoney the codewitch6-May-19 6:44 
GeneralRe: When is equal not equal? Pin
Dr.Walt Fair, PE6-May-19 10:36
professionalDr.Walt Fair, PE6-May-19 10:36 
GeneralRe: When is equal not equal? Pin
Super Lloyd6-May-19 15:04
Super Lloyd6-May-19 15:04 
GeneralRe: When is equal not equal? Pin
honey the codewitch7-May-19 2:31
mvahoney the codewitch7-May-19 2:31 
GeneralRe: When is equal not equal? Pin
englebart7-May-19 2:08
professionalenglebart7-May-19 2:08 
GeneralRe: When is equal not equal? Pin
honey the codewitch7-May-19 2:30
mvahoney the codewitch7-May-19 2:30 
GeneralRe: When is equal not equal? Pin
honey the codewitch7-May-19 2:34
mvahoney the codewitch7-May-19 2:34 
GeneralWSO CCC V VI MMXIX Pin
Tim Deveaux5-May-19 20:05
Tim Deveaux5-May-19 20:05 
GeneralRe: WSO CCC V VI MMXIX Pin
OriginalGriff5-May-19 20:22
mveOriginalGriff5-May-19 20:22 
GeneralRe: WSO CCC V VI MMXIX - Winner Pin
Tim Deveaux5-May-19 20:32
Tim Deveaux5-May-19 20:32 
GeneralRe: WSO CCC V VI MMXIX Pin
Johnny J.6-May-19 2:22
professionalJohnny J.6-May-19 2:22 
GeneralRe: WSO CCC V VI MMXIX Pin
OriginalGriff6-May-19 2:24
mveOriginalGriff6-May-19 2:24 
GeneralRe: WSO CCC V VI MMXIX Pin
DRHuff6-May-19 3:46
DRHuff6-May-19 3:46 
GeneralRe: WSO CCC V VI MMXIX Pin
OriginalGriff6-May-19 4:19
mveOriginalGriff6-May-19 4:19 
GeneralRe: WSO CCC V VI MMXIX Pin
DRHuff6-May-19 4:39
DRHuff6-May-19 4:39 
GeneralRe: WSO CCC V VI MMXIX Pin
User 48350476-May-19 4:47
User 48350476-May-19 4:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.