C++ Questions and Answers

Solve problems and approach solutions. Just ask and lurkers wi...
Rob
May 31, 2020 02:13
pastebin.com/bGNmAYgM < Any thoughts on this?
 

Lounge<C++>

Today we're daydreaming about C++26 reflection
Rob
May 24, 2020 11:45
story of my life
Dec 11, 2013 18:12
...
Dec 11, 2013 17:52
I guess SP can't really compare to a MMO in terms of wasted time, though
Dec 11, 2013 17:52
The Witcher 2 on hard is a pretty heavy time investment, and doesn't require parting with your monies monthly :)
Dec 3, 2013 20:51
...
Dec 3, 2013 19:21
lol
Dec 3, 2013 19:20
I got a bundle as a gift last week, don't know what to do with half the games
Dec 3, 2013 19:20
@EtiennedeMartel Did you mean "giving keys to friends," or is there some mechanism for giving games to charity?
Dec 2, 2013 10:07
Sorry to interrupt the philosophical discussion :) Those of you writing C++ on windows, what compiler do you (most often) use?
Dec 2, 2013 02:41
lol ooops, didn't read far back enough :)
Nov 29, 2013 22:21
@sehe My father would like that one, he's always bringing up Murphy's law for some reason or another
 

C#

General discussions about the c# language, Squirrels | gist.gi...
Feb 26, 2014 22:55
Regarding EF4, I have an IQueryable<int> subquery and wrote a Func<T, bool> predicate = o => subquery.Contains(o.SomeId) that I use to call IObjectSet<T>.Where(predicate) ... does anyone know offhand if subquery will be evaluated more than once?
Dec 19, 2013 04:59
Ahh, that could work nicely
Dec 19, 2013 04:54
It's no problem; our discussion has made me think that mapping the function table is probably the best approach after all, since EF will keep track of changes for me
Dec 19, 2013 04:50
Yes, I see. But if I've made a large batch of changes to the relationship property, how would I find them all without manually keeping track of all changes?
Dec 19, 2013 04:48
So if I do something like student.Course.Add(course1), both course1 and student will have their EntityState == EntityState.Unchanged ... the question is how to find the newly added relationship, so I can revert it?
Dec 19, 2013 04:43
@LINQ2Vodka I've already accomplished that in my application. My problem is how to search for relationships that have been added or deleted (before committing to the database with the SaveChanges() method), and reverting those changes.
Dec 19, 2013 04:25
Can you clarify?
Dec 19, 2013 04:20
Going with your example, if I add a new course to student.Courses, neither the student nor the course has been modified -- just the relationship, which I have no means of identifying ... that said, I'm starting to think I should just map the table.
Dec 19, 2013 04:16
I'm not sure how that would help. My problem is that because the junction table isn't mapped to a type in my model (and I don't really want to map it), I have no means of checking EntityState to find changes that haven't been saved, or calling ObjectContext.Refresh() to revert those changes
Dec 19, 2013 04:05
I don't think so, I believe it requires the FK be present in the table ...
Dec 19, 2013 03:55
Model first
Dec 19, 2013 03:54
@LINQ2Vodka I'm not familiar with HasMany or WithMany, are those newer additions to EF? I should have specified EF4
Dec 19, 2013 03:39
Does anyone happen to know how to refresh (from store) changes to a many-to-many relationship in Entity Framework, when the junction table has no FK and is not represented by a type in the model (just two relationship properties)?
Dec 19, 2013 03:36
Hi there
Dec 6, 2013 16:01
Howdy
 

Python

Room rules: sopython.com/chatroom Code formatting guide: tinyu...
Dec 11, 2013 18:08
Even real SO rep isn't very indicative of whether someone is suited for a job :P
Dec 11, 2013 18:07
Imo meta rep measures nothing important
Dec 11, 2013 18:06
Meh
Dec 11, 2013 18:00
Avocado!
Dec 11, 2013 17:59
Ahhh, ok
Dec 11, 2013 17:59
Hmm, is sopython.org down or is it just me?
Dec 11, 2013 17:56
Productive cabbage?
Dec 11, 2013 17:56
I've always wondered about this room's description
Dec 6, 2013 18:15
Just for hobby development projects in my personal time
Dec 6, 2013 18:15
That said, I don't use linux at work either
Dec 6, 2013 18:15
I think linux is the plural of linux ... if you want to be picky, say distros :p
Dec 6, 2013 18:13
I like it, but it's one of those choose-each-and-every-package-you-want-during-install distros
Dec 6, 2013 18:13
I've been using archlinux.org
Dec 6, 2013 18:12
There's a Debian edition as well
Dec 6, 2013 18:11
Aaaand I read further
Dec 6, 2013 18:11
howtogeek.com/115041/… < This says it's Ubuntu based
Dec 6, 2013 18:10
Hmm
Dec 6, 2013 18:10
Peter -- ah, that might be it
Dec 6, 2013 18:09
@PeterVaro Mint is pretty similar to Ubuntu, pretty sure it forked from Ubuntu a few years back
Dec 6, 2013 17:15
@PeterVaro The dark lord Cthulhu will always solve your problems.
Dec 6, 2013 16:14
Oh ... I completely missed Jon's comment :p
Dec 6, 2013 16:12
"This module is like violence: if it doesn't work, you just need more of it." ... fuckit(fuckit('some_shitty_module')) # This is definitely going run now. < just lol
Dec 6, 2013 16:11
@Kevin That's got to be one of the scariest things I've seen all week