Click here to Skip to main content
15,214,157 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.
 
GeneralRe: Not trying to make a political statement Pin
dandy7230-Jan-20 10:34
Memberdandy7230-Jan-20 10:34 
GeneralRe: Not trying to make a political statement Pin
Dave Kreskowiak30-Jan-20 11:44
mveDave Kreskowiak30-Jan-20 11:44 
GeneralRe: Not trying to make a political statement Pin
dandy7231-Jan-20 4:15
Memberdandy7231-Jan-20 4:15 
GeneralRe: Not trying to make a political statement Pin
Member 798912230-Jan-20 11:03
MemberMember 798912230-Jan-20 11:03 
GeneralRe: Not trying to make a political statement Pin
dandy7231-Jan-20 4:10
Memberdandy7231-Jan-20 4:10 
GeneralRe: Not trying to make a political statement Pin
honey the codewitch30-Jan-20 6:30
mvahoney the codewitch30-Jan-20 6:30 
GeneralRe: Not trying to make a political statement Pin
Member 798912230-Jan-20 11:04
MemberMember 798912230-Jan-20 11:04 
RantEncapsulation, is it so hard? Pin
honey the codewitch29-Jan-20 23:26
mvahoney the codewitch29-Jan-20 23:26 
Please when you write parsers, separate your parsing logic from the rest of your app's logic so the app's main code isn't actually tied directly to your parser's grammar!

I mean, I get there's going to be some intermingling between different areas of your code

but when I crack open a project, and I find a codebase where every section of the app is intimately tied to every other section of the app it's really frustrating.

For example, the parser in this case returns LexSpan classes which hold a text buffer, and start and end positions within that buffer. Great for parsing, so you know where your fragments of text are.

But then when you build say, your Regex syntax tree with it, DO NOT use LexSpans as your member fields! unpack the values therein for witch's sake!

Now if i want to implement a different parser i have to completely tear apart the app's core logic.

Lovely.
Real programmers use butterflies

GeneralRe: Encapsulation, is it so hard? Pin
OriginalGriff30-Jan-20 0:16
mveOriginalGriff30-Jan-20 0:16 
AnswerRe: Encapsulation, is it so hard? Pin
lopatir30-Jan-20 1:16
Memberlopatir30-Jan-20 1:16 
GeneralRe: Encapsulation, is it so hard? Pin
RugbyLeague30-Jan-20 0:27
MemberRugbyLeague30-Jan-20 0:27 
GeneralRe: Encapsulation, is it so hard? Pin
Richard MacCutchan30-Jan-20 0:42
mveRichard MacCutchan30-Jan-20 0:42 
GeneralRe: Encapsulation, is it so hard? Pin
GuyThiebaut30-Jan-20 0:34
professionalGuyThiebaut30-Jan-20 0:34 
GeneralRe: Encapsulation, is it so hard? Pin
Richard Deeming30-Jan-20 1:17
mveRichard Deeming30-Jan-20 1:17 
GeneralRe: Encapsulation, is it so hard? Pin
honey the codewitch30-Jan-20 4:31
mvahoney the codewitch30-Jan-20 4:31 
GeneralRe: Encapsulation, is it so hard? Pin
Richard Deeming30-Jan-20 4:56
mveRichard Deeming30-Jan-20 4:56 
GeneralRe: Encapsulation, is it so hard? Pin
honey the codewitch30-Jan-20 5:57
mvahoney the codewitch30-Jan-20 5:57 
GeneralRe: Encapsulation, is it so hard? Pin
Gerry Schmitz30-Jan-20 5:17
mveGerry Schmitz30-Jan-20 5:17 
GeneralRe: Encapsulation, is it so hard? Pin
honey the codewitch30-Jan-20 6:00
mvahoney the codewitch30-Jan-20 6:00 
GeneralRe: Encapsulation, is it so hard? Pin
dandy7230-Jan-20 5:24
Memberdandy7230-Jan-20 5:24 
GeneralRe: Encapsulation, is it so hard? Pin
honey the codewitch30-Jan-20 6:02
mvahoney the codewitch30-Jan-20 6:02 
GeneralAndroid location services Pin
Mark_Wallace29-Jan-20 22:31
MemberMark_Wallace29-Jan-20 22:31 
GeneralRe: Android location services Pin
Kornfeld Eliyahu Peter29-Jan-20 23:22
mveKornfeld Eliyahu Peter29-Jan-20 23:22 
GeneralRe: Android location services Pin
Jörgen Andersson29-Jan-20 23:37
professionalJörgen Andersson29-Jan-20 23:37 
GeneralRe: Android location services Pin
Paddington Bear30-Jan-20 1:16
MemberPaddington Bear30-Jan-20 1:16 

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.