hkaiser changed the topic of #ste||ar to: STE||AR: Systems Technology, Emergent Parallelism, and Algorithm Research | stellar-group.org | HPX: A cure for performance impaired parallel applications | github.com/STEllAR-GROUP/hpx | This channel is logged: irclog.cct.lsu.edu
Yorlik_ has joined #ste||ar
Yorlik has quit [Ping timeout: 265 seconds]
hkaiser has quit [Quit: Bye!]
tufei_ has quit [Remote host closed the connection]
K-ballo1 has joined #ste||ar
K-ballo has quit [Ping timeout: 252 seconds]
K-ballo1 is now known as K-ballo
hkaiser has joined #ste||ar
K-ballo has quit [Ping timeout: 260 seconds]
K-ballo has joined #ste||ar
hkaiser has quit [Quit: Bye!]
diehlpk_work has joined #ste||ar
<gonidelis[m]> hi yall. trying to understand this bit of code... (full message at <https://libera.ems.host/_matrix/media/v3/download/libera.chat/30b1edc842f4ac3f679d0dbe62d8a26fa138f1bc>)
<gonidelis[m]> are the clauses before `requires` also "requirements"? like "the specialization graph<G>" should be valid or sth?
<satacker[m]> is that `graph<T>` a concept?
<gonidelis[m]> ahhh! very nice
<gonidelis[m]> thanks!
<gonidelis[m]> (yes it is)
<gonidelis[m]> so it's just a bunch of predefined concepts + a newly defined one (requires)
<gonidelis[m]> thanks
<gonidelis[m]> yes of course
hkaiser has joined #ste||ar
hkaiser has quit [Quit: Bye!]
hkaiser has joined #ste||ar
Yorlik_ has quit [Ping timeout: 256 seconds]
K-ballo1 has joined #ste||ar
<gonidelis[m]> anyone understand what this line means?
<gonidelis[m]> `{ *in } -> std::same_as<std::iter_reference_t<In>>;`
<gonidelis[m]> i thought `same_as<>` takes two template arguments
<hkaiser> it's concept requiring that whatever *it returns needs to be the same as the reference type exposed by the iterator it
<hkaiser> is_same_as requires two arguments, same_as is a concept as well
K-ballo has quit [Ping timeout: 260 seconds]
K-ballo1 is now known as K-ballo
<hkaiser> IOW, if an iterator exposes T as it's reference type, then operator*() should return T
K-ballo has quit [Ping timeout: 256 seconds]
K-ballo1 has joined #ste||ar
K-ballo1 is now known as K-ballo
<gonidelis[m]> makes sense
<gonidelis[m]> thanks
<gonidelis[m]> Hartmut, I cannot find any reference to std::is_same_as
<hkaiser> gonidelis[m]: it's just is_same<T1, T2>, sorry
<gonidelis[m]> I only see same_ss which takes two arguments and this one takes only one. i reckon it's a metafunction?
<gonidelis[m]> oh my god
<K-ballo> sometimes a concept expression can omit one parameter and it is deduced from the context
<gonidelis[m]> but this is not the case here
<K-ballo> this is the case here
<K-ballo> there's two arguments to `std::same_as`, one explicit, one deduced
<gonidelis[m]> so it's not the c++11 <type_traits> std::same_as ?
<hkaiser> same_as is the concept
<K-ballo> same_as is a concept, not a c++11 trait
<gonidelis[m]> ok scratch it
<gonidelis[m]> is_same != same_as
<gonidelis[m]> i just noticed :)
<K-ballo> same_as does subsumption, which the is_same trait simply cant
<gonidelis[m]> alright
<gonidelis[m]> what kind of subsumption? how does it deduce the second arg?
<hkaiser> c++ susumption
<K-ballo> same_as<X, Y> subsumes same_as<Y, X>
<K-ballo> whereas is_same<X, Y> and is_same<Y, X> are distinct and unrelated to each other
<gonidelis[m]> ok yeah
<gonidelis[m]> but still it does not answer how a concept that accepts two arguments (std::same_as) can work with one argument, right?
<K-ballo> it's deduced from context, as said above
<gonidelis[m]> cppref does not mention how.
<K-ballo> in that particular context, giving two explicit arguments would not even be allowed
<gonidelis[m]> neither does the standard
<gonidelis[m]> yes it makes sense semantically
<gonidelis[m]> but how does the compiler not complaining
<K-ballo> the compiler would complain if there were two explicit arguments
<gonidelis[m]> where is that stated?
<K-ballo> in the standard
<gonidelis[m]> i am probably looking at the wrong section
<K-ballo> in the standard for concepts
<K-ballo> type-constraints in this particular context
<K-ballo> it applies to all concepts, not just same_as
<gonidelis[m]> yeah i believe you
<gonidelis[m]> i am just looking to find out where it's stated
<gonidelis[m]> Explicit instantiations, explicit specializations, or partial
<gonidelis[m]> specializations of concepts are not allowed (the meaning of the original
<gonidelis[m]> definition of a constraint cannot be changed).
<gonidelis[m]> partial specializations of concepts are not allowed
<gonidelis[m]> ah!!!
<gonidelis[m]> ```
<gonidelis[m]> In a type-constraint, a concept takes one less template argument than its parameter list demands, because the contextually deduced type is implicitly used as the first argument of the concept.
<gonidelis[m]> ```
<K-ballo> that does not sound like the standard.. is it in a note?
<gonidelis[m]> yeah that's from cppref
<gonidelis[m]> but I understand now how
<gonidelis[m]> it's the contextualy deduced type
<gonidelis[m]> contextually*
<K-ballo> [temp.param]/4
<gonidelis[m]> may I ask, what is a "type-constraint" ?
<K-ballo> the thing after the ->
<gonidelis[m]> thanks
<gonidelis[m]> type-constrains are types of concepts, right?
<gonidelis[m]> constraints*
diehlpk_work has quit [Remote host closed the connection]