TiarkRompf / virtualization-lms-core

A Framework for Runtime Code Generation and Compiled DSLs
http://scala-lms.github.com
BSD 3-Clause "New" or "Revised" License
324 stars 91 forks source link

Array buffer ops and Typ API improvements #107

Closed alexeyr closed 7 years ago

alexeyr commented 8 years ago

Not confident about https://github.com/scalan/virtualization-lms-core/commit/d41b2b86a29c83bfc1b9d8b72052ba5bb1576d01: is this the correct implementation? I do know that we needed it in Scalan and it seems to work.

TiarkRompf commented 8 years ago

I think I'd prefer to keep the pattern of

def foo[T:Typ:Numeric](....)

and then using typ[T] in the body of foo instead of adding implicit mA: Typ[T] as "explicit implicit".

It's a small thing, but I find it useful to have the requirements next to the type parameter in the signature instead of having to look all the way to the right.

Otherwise, happy to merge all the rest.

alexeyr commented 8 years ago

I think I'd prefer to keep the pattern of ...

Done.