Re: something other than C

2016-05-04 Thread Artyom Shalkhakov
On Wednesday, May 4, 2016 at 7:33:37 AM UTC+6, Brandon Barker wrote: > > I at least would probably use ATS/Java co-programming for something > eventually -- somewhat surprisingly (though not in retrospect) I have > yet to take on even one C/C++ project in the last 1.5 years but have > had three

Re: very light-weight cooperative concurrency?

2016-05-04 Thread Artyom Shalkhakov
On Wednesday, May 4, 2016 at 5:20:43 AM UTC+6, Raoul Duke wrote: > > > atscc2erl > > I had no idea. :-) > Here's a good read: http://arxiv.org/abs/1603.03727 (I think HX won't post it out of modesty. :-)) -- You received this message because you are subscribed to the Google Groups "ats-lang-us

Re: where to file tickets / discuss issues?

2016-05-06 Thread Artyom Shalkhakov
On Friday, May 6, 2016 at 11:32:11 AM UTC+6, Raoul Duke wrote: > > e.g. I get quite a few warnings when building on Ubuntu 14.04 x86. > Please post to GitHub: https://github.com/githwxi/ATS-Postiats -- You received this message because you are subscribed to the Google Groups "ats-lang-users

Re: glot.io, a code pastebin that can also run your code, now supports ATS.

2016-05-09 Thread Artyom Shalkhakov
OK, here's my attempt: https://glot.io/snippets/eei9ulhfry The one-hole contexts remind of the dataviews used in old AVL tree and RB tree implementations (from ATS1 libats/ngc) that were used to reconstruct the trees after rebalancing. On Sunday, May 8, 2016 at 12:18:45 AM UTC+6, Steinway Wu w

Re: Embedding differential equations into types

2016-05-11 Thread Artyom Shalkhakov
On Thursday, May 12, 2016 at 5:56:56 AM UTC+6, gmhwxi wrote: > > Adding a 2d-oscillator example: > > > http://www.cs.bu.edu/~hwxi/GitHub/ATS-Postiats-contrib/projects/LARGE/DREACH/SCRATCH/oscillator/ > > http://www.cs.bu.edu/~hwxi/GitHub/ATS-Postiats-contrib/projects/LARGE/DREACH/SCRATCH/oscillator

Re: to the jvm!

2016-05-20 Thread Artyom Shalkhakov
On Friday, May 20, 2016 at 5:14:56 AM UTC+6, Raoul Duke wrote: > > https://github.com/davidar/lljvm > possibly interesting. > I'm sorry, it doesn't seem to be actively maintained. There is also a possibly newer fork, here: https://github.com/hyc/lljvm I don't know if it will help or not. What

Re: to the jvm!

2016-05-20 Thread Artyom Shalkhakov
On Friday, May 20, 2016 at 1:55:37 PM UTC+6, Artyom Shalkhakov wrote: > > On Friday, May 20, 2016 at 5:14:56 AM UTC+6, Raoul Duke wrote: >> >> https://github.com/davidar/lljvm >> possibly interesting. >> > > I'm sorry, it doesn't seem to be actively m

Lexical format for floating-point constants

2016-06-27 Thread Artyom Shalkhakov
I'm doing a syntax highlighter for ATS based on the Monarch editor (used in Visual Studio Code) and I'm interested to know what's the lexical grammar for floating-point constants? I've tried looking through the lexer source code, but I find it quite complicated. I'd like some help on this one.

Re: Lexical format for floating-point constants

2016-06-27 Thread Artyom Shalkhakov
z](HEX0)) > DOT = [.] > EXP = [pP](INT1) > > HEXFLOAT = (HEX1)(EXP) | (HEX1)(DOT)(HEX0)(EXP?) | (DOT)(HEX1)(EXP?) > > In C, EXP? should be EXP for hexadecimal floating point numbers. > > On Monday, June 27, 2016 at 4:06:42 AM UTC-4, Artyom Shalkhakov wrote: >> >&

Re: Lexical format for floating-point constants

2016-06-29 Thread Artyom Shalkhakov
dy, I will give it a try. > I'm currently in the process of writing unit-tests (caught a bug with a comment already!). It's taking quite some time. Will let you know if something fruitful comes out of it. > > On Monday, June 27, 2016 at 11:58:42 AM UTC-4, Artyom Shalkhakov wrote:

Re: A demo of memorizing functions in ATS

2016-07-13 Thread Artyom Shalkhakov
Hello Steinway, On Monday, July 11, 2016 at 7:15:10 AM UTC+6, Steinway Wu wrote: > > Hi, > > In a practice, I encountered a problem of memorizing functions. Given a > function `f`, a memorized version of `f`, called `memo f` should cache the > results of `f` applying on some `input`. I tried a

Re: Lexical format for floating-point constants

2016-08-15 Thread Artyom Shalkhakov
The PR adding ATS/Postiats colorization support to Monaco editor has been merged. On Thursday, June 30, 2016 at 9:17:56 AM UTC+6, Artyom Shalkhakov wrote: > > On Wednesday, June 29, 2016 at 9:54:39 AM UTC+6, gmhwxi wrote: >> >> >> Thanks for the effort! >> >

Re: Lexical format for floating-point constants

2016-08-16 Thread Artyom Shalkhakov
rhcloud.com/assign01 > view-source:http://myflask-tutoriats.rhcloud.com/assign01 > Sure! I will see if I can do something ASAP. (Pretty busy with other stuff lately...) > > Thanks! > > On Tuesday, August 16, 2016 at 12:07:35 AM UTC-4, Artyom Shalkhakov wrote: >> >>

Re: Ask/Answer ATS-related questions on StackOverflow

2016-10-19 Thread Artyom Shalkhakov
On Sunday, October 16, 2016 at 12:20:59 AM UTC+6, gmhwxi wrote: > > > Kudos to Hanwen: > > http://stackoverflow.com/tags/ats/info > > For simple questions on using ATS, please think about asking/answering > them on StackOverflow. Of course, you are always welcome to add a link > here to a question

Re: Compiling via g++ the output of Patsopt

2016-11-24 Thread Artyom Shalkhakov
On Saturday, November 19, 2016 at 2:28:08 AM UTC+6, gmhwxi wrote: > > > I have long been wanting to tap into the power of C++ when programming in > ATS. > To some extent, compiling ATS/arduino is the first example of this kind. > But ATS/arduio > makes only very limited use of C++. > > Now I have

Pretty printing ATS compiler errors

2016-12-22 Thread Artyom Shalkhakov
Hello all, I've built this little tool: https://ashalkhakov.github.io/pats-ef/ The idea is to ease the burden of reading compiler error messages, and I'd like some feedback. Currently it only tries to parse the ASTs printed by the ATS compiler into some JSON format (planned feature: visualizat

Re: patsopt-nodejs for patsopt-functionalities via nodejs

2017-01-20 Thread Artyom Shalkhakov
Hello Hongwei, Where is the source code of these packages? For instance, I don't see the GitHub button in here: https://www.npmjs.com/package/atsccomp-atscc2js On Tuesday, January 17, 2017 at 7:55:23 PM UTC+6, gmhwxi wrote: > > FYI. > > I just published a package patsopt-nodejs under npm. > My

Re: patsopt-nodejs for patsopt-functionalities via nodejs

2017-01-20 Thread Artyom Shalkhakov
Another idea is to use these packages to implement a really simple loader for Webpack. Like I recently did with Jison: https://github.com/ashalkhakov/jison-loader With such a loader, it would be easy to combine ATS JS code with the rest of the ecosystem. Neat! On Tuesday, January 17, 2017 at

Re: Typechecking error involving Either datatype

2017-02-20 Thread Artyom Shalkhakov
Hi August, You could use this tool: https://ashalkhakov.github.io/pats-ef/ to turn the error message into a structured tree. If it doesn't work for you (or the tree produced isn't that useful but you have some ideas how to fix it), you could file a bug on GitHub: https://github.com/ashalkhako

Re: ATS Redirection

2017-02-22 Thread Artyom Shalkhakov
Hello shokoofa Hosseini, On Wednesday, February 22, 2017 at 11:41:40 AM UTC+6, shokoofa Hosseini wrote: > > Hello everybody > I wonder if anyone can help me > > I want to use ATS to redirect my traffic to more than one node. I do not > know how and where to configure my service in this way. > Sh

Re: (Co)monads in ATS

2017-03-18 Thread Artyom Shalkhakov
Hi August, On Thursday, March 16, 2017 at 9:20:54 PM UTC+6, August Alm wrote: > > Hi all! > > I just wrote down some sketchy thoughts on monads and comonads in ATS. ATS > has a very unique type system, so there are (co)monads in ATS that simply > do not exist in other languages. I'm wondering if

Re: using static quantifiers as dynamical terms

2017-04-11 Thread Artyom Shalkhakov
On Wednesday, April 12, 2017 at 5:16:50 AM UTC+6, August Alm wrote: > > I have a function that looks as follows: > > fun{} > parallel_composition_aux > {m1, n1, m2, n2: nat} > (m1: int m1, p1: processor(m1, n1), p2: processor(m2, n2)): > processor(m1+m2,

Re: pandoc supports ATS syntax highlighting

2017-04-17 Thread Artyom Shalkhakov
On Tuesday, April 18, 2017 at 10:34:48 AM UTC+6, Kiwamu Okabe wrote: > > Yes :) > Implement silently, don't tell anyone. Have it spring up from an unrelated source. You just made my day, thanks, Kiwamu. :) > > On Apr 18, 2017 7:45 AM, "gmhwxi" > wrote: > >> author="Kiwamu Okabe (...)" >> >> O

Re: The myatscc utility

2017-04-26 Thread Artyom Shalkhakov
Hi Hongwei, On Wednesday, April 26, 2017 at 6:24:19 AM UTC+6, gmhwxi wrote: > > > Often a file of ATS source code has to be compiled with the use of a > Makefile. > This can be quite inconvenient in practice. > > When teaching, I have to answer countless questions regarding the need of > certain

Re: Packaging ats3d

2017-04-26 Thread Artyom Shalkhakov
On Thursday, April 27, 2017 at 12:17:02 PM UTC+6, gmhwxi wrote: > > > Packaging ATS code is largely undocumented at this point. > > I suggest that we use ats3d (https://github.com/ashalkhakov/ats3d) > as a concrete example to illustrate some key steps involved in forming > an npm-package for ATS co

Re: Packaging ats3d

2017-04-27 Thread Artyom Shalkhakov
On Thursday, April 27, 2017 at 2:56:23 AM UTC-4, Artyom Shalkhakov wrote: >> >> On Thursday, April 27, 2017 at 12:17:02 PM UTC+6, gmhwxi wrote: >>> >>> >>> Packaging ATS code is largely undocumented at this point. >>> >>> I suggest that w

Re: Packaging ats3d

2017-04-27 Thread Artyom Shalkhakov
so, there are files like xyz~ in the package. You may want to remove > them. > > This is what I was trying to avoid. But maybe it's there because it got into version control... We'll see. > > On Thursday, April 27, 2017 at 11:33:53 AM UTC-4, Artyom Shalkhakov wrote: >&g

Re: Packaging ats3d

2017-04-27 Thread Artyom Shalkhakov
at link-time. > > Various occurrences of "../CATS/vector.cats" are changed into > > "atscntrb-as-ats3d/src/CATS/vector.cats" > > # > > Thank you very much for the suggestions! I will take a look this weekend. > On Thursday, April 27, 2017 at 11:58:44 AM

Re: Packaging ats3d

2017-05-01 Thread Artyom Shalkhakov
r testing packages externally, please visit: > > https://github.com/githwxi/ATS-Postiats-test/tree/master/package > > On Thursday, April 27, 2017 at 11:17:50 PM UTC-4, Artyom Shalkhakov wrote: >> >> 2017-04-28 9:11 GMT+06:00 gmhwxi <...>: >> > >> >

Re: Packaging ats3d

2017-05-06 Thread Artyom Shalkhakov
should create some files, e.g. test04.exe generates PPM images in data/ subdirectory (they all are named like X-out.ppm, where X is the name of the corresponding Wavefront OBJ file). On Monday, May 1, 2017 at 8:50:48 PM UTC+6, Artyom Shalkhakov wrote: > > Hongwei, > > Sorry for this ta

Handling command line arguments?

2017-05-09 Thread Artyom Shalkhakov
Hi all, Is there a ready-made library for handling command line parameters? So far I found the following: https://github.com/githwxi/ATS-Postiats/blob/master/utils/jsonlst2arr/jsonlst2arr.dats Which sets up an example of what HX thinks should be done to deal with command-line arguments. Would

Re: Handling command line arguments?

2017-05-14 Thread Artyom Shalkhakov
things up in a way that allows the code to work inside ATS and also >> work as >> a stand-alone package. >> >> On Wednesday, May 10, 2017 at 8:59:22 AM UTC-4, gmhwxi wrote: >>> >>> Good point! >>> >>> I have some ideas about this. I

Re: Handling command line arguments?

2017-05-16 Thread Artyom Shalkhakov
sh forward the ATS-as-a-better-C/C++ idea. > On Sunday, May 14, 2017 at 5:16:08 AM UTC-4, Artyom Shalkhakov wrote: >> >> >> >> On Saturday, May 13, 2017 at 6:38:59 PM UTC+6, gmhwxi wrote: >>> >>> >>> Now, this package is functioning. >>

Re: language-ats: ATS Support for Atom Text Editor

2017-06-13 Thread Artyom Shalkhakov
Hi Spencer, On Sunday, June 11, 2017 at 2:32:25 AM UTC+6, Spencer Hayes wrote: > > Hello Everyone, > > In case there are any of you who use Atom, I have released a preliminary > version of an ATS language pack for Atom titled "language-ats". You can > find more information about it on its Atom p

Babelfish (AST parsing)

2017-06-20 Thread Artyom Shalkhakov
Hello all, Today I've stumbled upon this project: https://www.gitbook.com/book/bblfsh/documentation/details And we could create a driver targeted to ATS parsing by using their SDK: https://doc.bblf.sh/driver/sdk.html I guess this can be a worthwhile project. -- You received this message beca

Deech's talk and slides from StrangeLoop 2017

2017-10-02 Thread Artyom Shalkhakov
Seen on reddit: https://www.reddit.com/r/programming/comments/73lhj0/a_not_so_gentle_introduction_to_systems/ Also see the discussion on r/rust: https://www.reddit.com/r/rust/comments/73j4p5/a_not_so_gentle_introduction_to_systems/ Cheers! -- You received this message because you are subscrib

Re: implement template based function on dependent type

2017-10-02 Thread Artyom Shalkhakov
On Sunday, October 1, 2017 at 7:11:19 PM UTC+6, gmhwxi wrote: > > I wrote something like this: > > extern > fun > {a:t@ype} > minus(x: a, y: a): a > extern > fun > {a:t@ype} > list_minus > {n:int} > (xs : list(a,n), ys : list(a,n)): list(a,n) > > implement > (a,n) > minus(xs, ys) = list_minus(xs, y

Re: implement template based function on dependent type

2017-10-02 Thread Artyom Shalkhakov
dats#L722 A type is defined on the spot to help with instantiation of templates. > > On Monday, October 2, 2017 at 3:04:00 AM UTC-4, Artyom Shalkhakov wrote: >> >> On Sunday, October 1, 2017 at 7:11:19 PM UTC+6, gmhwxi wrote: >>> >>> I wrote something like

Simple linear objects in ATSCC2JS

2017-10-04 Thread Artyom Shalkhakov
Hello all, Here's an example of a simple linear object in ATS: https://github.com/ats-lang/ats-lang.github.io/blob/master/DOCUMENT/INT2PROGINATS/CODE/CHAP_ABSVTYPE/timer.dats Can this be adapted to work in ATSCC2JS? This code: https://gist.github.com/ashalkhakov/85902ec8992acef7eef3fbf0a1c41dd

Re: convert primitives (int,float,...) to string (or linear string). Convert native char* to string and reversed ?

2017-10-07 Thread Artyom Shalkhakov
ATS has multiple types for strings: non linear (string, also length-indexed) linear (strbuf for C-like construction purposes, strptr and length-indexed strnptr) If you want to temporarily create a string, and then discard it, you could use strptr. There is also a contrib package for ref-counted

Re: ATS mode indentation

2017-10-13 Thread Artyom Shalkhakov
This is awesome! I'll try it on the weekend. Thank you! 14 окт. 2017 г. 1:24 AM пользователь "Andrew Knapp" написал: Both of those test cases should work now, as well as a lot of others. Some of the weird starting errors have been fixed, especially at the top level, but it won't be possible in t

ATStead: in-browser structured editing in ATS

2017-10-19 Thread Artyom Shalkhakov
Hello all, I'd like to share ATStead: https://rawgit.com/ashalkhakov/ATStead/master/src/index.html It is a simple structured editor based on: http://www.cs.ox.ac.uk/bernard.sufrin/edit.pdf Try it to see if you can enter some expressions! Structured editors are known to be clunky, but this one

Re: ATStead: in-browser structured editing in ATS

2017-10-19 Thread Artyom Shalkhakov
oint me to the datatype that you use for that language? The current object language in ATStead has "lam" an "app" constructs, but not "fix" or "ifnz". On Thursday, October 19, 2017 at 12:09:59 PM UTC-4, Artyom Shalkhakov wrote: >> >> Hello all,

libatscc2js-rt: npm package for the libatscc2js runtime

2017-10-28 Thread Artyom Shalkhakov
Hello all, I've published this package here: https://www.npmjs.com/package/libatscc2js-rt At first I was simply linking to the official files distributed on the website, but it really doesn't work very good if you are on a flaky Internet connection. Now, if you have a project that uses *atscc

Re: libatscc2js-rt: npm package for the libatscc2js runtime

2017-10-28 Thread Artyom Shalkhakov
in ATS-Postiats/contrib is under MIT license. On Sat, Oct 28, 2017 at 10:15 AM, Artyom Shalkhakov < artyom.shalkha...@gmail.com> wrote: > Hello all, > > I've published this package here: > > https://www.npmjs.com/package/libatscc2js-rt > > At first I was simply l

Re: libatscc2js-rt: npm package for the libatscc2js runtime

2017-10-29 Thread Artyom Shalkhakov
all_in_one'. Then > take > a look at the 'output' directory. > > I'll add a package.json into that directory and then submit a PR to you, if you don't mind. > > > On Sat, Oct 28, 2017 at 11:25 AM, Artyom Shalkhakov > wrote: > >> How d

Re: proof search for a view in array fails

2018-01-05 Thread Artyom Shalkhakov
On Friday, January 5, 2018 at 6:26:59 PM UTC+6, Chris Double wrote: > > With the following code: > > fun test {l:agz}(pf: !array_v(int, l, 2)| p: ptr l): void = let >prval (pf_x, pf_xs) = array_v_uncons(pf) >prval (pf_x1, pf_xs1) = array_v_uncons(pf_xs) >val () = !p := 0 >val p

Re: In Praise of Hongwei

2018-02-08 Thread Artyom Shalkhakov
Indeed it's a curious thing. I've been following Hongwei's commits for the last 8 years and he has made an impact on the way I view and practice programming. Thanks much, Hongwei! 9 февр. 2018 г. 2:55 ДП пользователь "Yves Cloutier" < yves.clout...@gmail.com> написал: I've been keeping an eye o

Re: ATS3: ATS/Xanadu

2018-02-13 Thread Artyom Shalkhakov
If we talk syntax, why not adopt that of C? :-) 13 февр. 2018 г. 8:43 ПП пользователь "August Alm" написал: I second the preference for Haskell-style "let" and "where", which is to say no "end"s and no curly braces. Of course, this requires indentation to be syntactic and not just a matter of ae

Re: ATS3: ATS/Xanadu

2018-02-20 Thread Artyom Shalkhakov
On Saturday, February 10, 2018 at 12:15:22 AM UTC+6, gmhwxi wrote: > > For the moment, I just want to open a thread for ATS3. > > I decided to pick ATS/Xanadu for the full project name. I like the name > Xanadu > because it is poetic and brings a feel of exoticness. > > ATS3 is supposed to be co

Re: ATSPackage: a build tool/package manager for ATS

2018-02-20 Thread Artyom Shalkhakov
Hi, On Sunday, February 18, 2018 at 12:50:54 PM UTC+6, vamc...@gmail.com wrote: > > Hi all, > > I have been working on atspkg for > some time now, and it finally has a stable configuration format, so I > figured the wider ATS community could benefit. > > It's

Re: Intro to ATS - How to code productively

2018-03-28 Thread Artyom Shalkhakov
Hi Lance, On Tuesday, March 27, 2018 at 9:40:55 PM UTC+6, Lance Galletti wrote: > > Hi ats users! > > I recently had the opportunity to give a talk at a hackathon about ATS and > coding productivity / quality. I thought I would share my slides here: > > > https://docs.google.com/presentation/d/15

Re: Flat memory underlying dataviewtypes

2018-03-28 Thread Artyom Shalkhakov
Hi Andrew, Could you please post a link to the library? Thanks. :) On Wednesday, March 21, 2018 at 12:35:46 AM UTC+6, Andrew Knapp wrote: > > Hello, > > I'd like to be able to send dataviewtypes as messages in a low-latency ipc > library I've written. > > In this scenario, any use of malloc is u

Re: Example code for traits/mixins/multiple inheritance

2018-03-28 Thread Artyom Shalkhakov
Hi Brandon, On Saturday, March 10, 2018 at 3:50:19 AM UTC+6, Brandon Barker wrote: > > There is a small part of a project > I'd like to convert > to ATS where linear types could be helpful in tracking cancellation of > running tasks (and othe

Re: Intro to ATS - How to code productively

2018-03-28 Thread Artyom Shalkhakov
ng together what I have learned from > Hongwei's classes and books but I will definitely be checking out HtDP - > thank you for the suggestion! > > > On Wednesday, March 28, 2018 at 3:13:37 AM UTC-4, Artyom Shalkhakov wrote: >> >> Hi Lance, >> >>

Re: Intro to ATS - How to code productively

2018-03-31 Thread Artyom Shalkhakov
hank you! Looking forward to it! :) > > On Wednesday, March 28, 2018 at 12:00:14 PM UTC-4, Artyom Shalkhakov wrote: >> >> On Wednesday, March 28, 2018 at 9:34:37 PM UTC+6, Lance Galletti wrote: >>> >>> Hi Artyom! >>> >>> Thank you for your feedbac

Re: Intro to ATS - How to code productively

2018-04-01 Thread Artyom Shalkhakov
the implementation details to a later point. C can > probably do this via pointers or structs, but then you need to think about > the details of a struct. > > Indeed! This is certainly the way to go. > On Saturday, March 31, 2018 at 7:49:39 AM UTC-4, Artyom Shalkhakov wrote:

ATS/C programming: a book

2018-04-05 Thread Artyom Shalkhakov
Hi all, I wrote this intro here: https://ashalkhakov.gitbooks.io/ats-c-programming/content/ The idea is to provide a better learning experience for C programmers (and maybe C++ programmers). The plan is to cover these things: 1. handling command line arguments (the argv type in ATS) 2. workin

Re: Shared memory IPC in ATS

2018-04-08 Thread Artyom Shalkhakov
g-users/68d837ee-dd85-4f25-b24b-016904922bd4% > 40googlegroups.com > <https://groups.google.com/d/msgid/ats-lang-users/68d837ee-dd85-4f25-b24b-016904922bd4%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Cheers, Artyom Shalkhakov -- You received this m

Re: Functions from datasorts to datasorts

2018-04-08 Thread Artyom Shalkhakov
le.com/d/ > msgid/ats-lang-users/2a781501-946c-48d0-8535-a2545ebce689% > 40googlegroups.com > <https://groups.google.com/d/msgid/ats-lang-users/2a781501-946c-48d0-8535-a2545ebce689%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Cheers, Artyom Shalkhakov

Re: Nix

2018-05-01 Thread Artyom Shalkhakov
0af26-dc72-4955-9ffe-5591d05022e2% > 40googlegroups.com > <https://groups.google.com/d/msgid/ats-lang-users/cdb0af26-dc72-4955-9ffe-5591d05022e2%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Cheers, Artyom Shalkhakov -- You received this messag

Re: Nix

2018-05-01 Thread Artyom Shalkhakov
it like that, just as a distro for my laptop. Brandon, would you kindly chime in? On Tuesday, May 1, 2018 at 11:29:29 PM UTC-4, Artyom Shalkhakov wrote: >> >> Hi Steinway, >> >> These days Brandon Barker maintains ATS packages for NixOS: >> >> https://github

Re: Blockchain + Smart Contract in ATS - looking for collaborators

2018-05-03 Thread Artyom Shalkhakov
Hi Lance, On Friday, April 27, 2018 at 10:17:01 PM UTC+6, Lance Galletti wrote: > > Hey ATS users! > > I recently had the chance to build a blockchain and smart contract > language in ATS - all with a nice CLI thanks to > https://github.com/ashalkhakov/colorado. > > I wrote a small blog post abo

Re: ATS license

2018-05-03 Thread Artyom Shalkhakov
On Wednesday, May 2, 2018 at 6:45:35 PM UTC+6, gmhwxi wrote: > > > FYI. > > I learned recently that LGPLv3 does address the issue of code generated > from templates (C++ templates, Ada generics). So I reworded ATS license > as follows. The change is that ATS libraries are now covered under LGPLv3.

Re: Blockchain + Smart Contract in ATS - looking for collaborators

2018-05-04 Thread Artyom Shalkhakov
for example (instead of command line), or if you would like to > implement different languages etc you can fork and (hopefully) just > copy-paste your code. > > I would love to hear your thoughts if you have other suggestions as well! > > > On Thursday, May 3, 2018 at 11:30:13

Re: Linear component is abandoned ...

2018-05-27 Thread Artyom Shalkhakov
Hi Aditya, I guess you will need to free it? пн, 28 мая 2018 г., 7:19 aditya siram : > Hi, > I have the following simplified version of assiging to a stack variable > and am getting the following error: > > "linear component of the following type is abandoned: > [S2Eapp(S2Ecst(option_vt0ype_bool

Re: Linear component is abandoned ...

2018-05-27 Thread Artyom Shalkhakov
unday, May 27, 2018 at 8:23:20 PM UTC-5, Artyom Shalkhakov wrote: >> >> Hi Aditya, >> >> I guess you will need to free it? >> >> пн, 28 мая 2018 г., 7:19 aditya siram : >> >>> Hi, >>> I have the following simplified version of assiging to a

Re: Cross-compiling for Windows

2018-08-02 Thread Artyom Shalkhakov
group, send email to ats-lang-users@googlegroups.com. > Visit this group at https://groups.google.com/group/ats-lang-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ats-lang-users/2171b521-923c-a366-0b67-e4a1d791f354%40iohk.io > . > -- Cheers

Re: Difficulties with performance in ATS

2018-08-05 Thread Artyom Shalkhakov
Great to hear that you got on par with C performance-wise! One other thing I'd like to draw attention to is allocation of [column]: in C code, it is via [alloca], so it gets freed as soon as the control exits the function, but in ATS code, [malloc] (or some such) is used, and then, a cast from [ar

Re: Postiats and C errors with array

2018-08-06 Thread Artyom Shalkhakov
nsubscribe from this group and stop receiving emails from it, send an > email to ats-lang-users+unsubscr...@googlegroups.com. > To post to this group, send email to ats-lang-users@googlegroups.com. > Visit this group at https://groups.google.com/group/ats-lang-users. > To view this discussion on th

Re: An "I suck at ATS" screencast

2018-08-16 Thread Artyom Shalkhakov
Hi Julian! I have to admit, I too suck at ATS! :-) Humility helps a great deal! чт, 16 авг. 2018 г., 13:19 Julian Fondren : > Found here: https://www.bitchute.com/video/arsFOT0Apsw2/ > > I have some other videos in advance, so I'll try to be regular about > uploading them. > > The first is just

Re: An "I suck at ATS" screencast

2018-09-05 Thread Artyom Shalkhakov
sers@googlegroups.com. > Visit this group at https://groups.google.com/group/ats-lang-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ats-lang-users/e1add075-fb66-491c-9f31-e54c26c9494d%40googlegroups.com > <https://groups.google.com/d/msgid/ats-

Re: ATS3: Parsing

2018-10-10 Thread Artyom Shalkhakov
Hi Hiroshi, On Thursday, October 11, 2018 at 7:56:53 AM UTC+3, Hiroshi Sakurai wrote: > > Why your a line of code is very short? > Do you write program using Smart phone? > That seems like a correct observation. :-) It's narrow enough to fit on my phone! > > 2018年10月11日木曜日 10時32分09秒 UTC+9 gmh

Re: GADT question

2018-10-16 Thread Artyom Shalkhakov
Chris, What if a runtime tag for type is introduced? datatype rtti (t@ype) = | Rbool(bool) | Rint(int) and then in Eq: | Eq(bool) of (rtti(a), Expr a, Expr a) during evalution there would be some kind of dynamic check on the tag as well. Another idea is to make [eval] evaluate to some

Re: Why my code occurs `unsolved constraint` error?

2018-10-29 Thread Artyom Shalkhakov
Hi Kiwamu, While I'm not sure why your code fails, it's an interesting project you've started. Please don't hesitate telling us more about it! Actually, I have an idea about your code. You may have to an annotation like if :( line: strnptr(m) ) => .. then ... else ... onto your conditionals.

Re: Why my code occurs `unsolved constraint` error?

2018-11-01 Thread Artyom Shalkhakov
Hi Kiwamu, чт, 1 нояб. 2018 г. в 10:00, Kiwamu Okabe : > Dear Artyom and Hongwei, > sorry for my late reply. > > On Mon, Oct 29, 2018 at 5:17 PM Artyom Shalkhakov > wrote: > > While I'm not sure why your code fails, it's an interesting project > you've

Re: Why my code occurs `unsolved constraint` error?

2018-11-05 Thread Artyom Shalkhakov
Hi Kiwamu, Sorry for the delay, I missed your reply. On Friday, November 2, 2018 at 5:29:00 AM UTC+2, Kiwamu Okabe wrote: > > Dear Hongwei and Artyom, > > On Fri, Nov 2, 2018 at 12:03 PM gmhwxi > > wrote: > > The way you wrote the code makes it a bit difficult to > > do typechecking. Try to c

Re: where do I get atscc2js from?

2018-11-06 Thread Artyom Shalkhakov
gt; To view this discussion on the web visit > https://groups.google.com/d/msgid/ats-lang-users/47e55746-fbe8-4ca1-9847-fcb7da889e18%40googlegroups.com > <https://groups.google.com/d/msgid/ats-lang-users/47e55746-fbe8-4ca1-9847-fcb7da889e18%40googlegroups.com?utm_medium=email&utm_source

Re: where do I get atscc2js from?

2018-11-06 Thread Artyom Shalkhakov
osed to have all the stuff from that dir in order to be able to run > that make? > > On Tuesday, November 6, 2018 at 5:01:11 PM UTC+1, Artyom Shalkhakov wrote: >> >> Hi Dmitry, >> >> Welcome! >> >> вт, 6 нояб. 2018 г. в 17:42, Dmitry Kouznetsov : >> &

Re: where do I get atscc2js from?

2018-11-06 Thread Artyom Shalkhakov
^* > > *./CATS-parsemit/CATS/catsparse_all_dats.c:98757:111: **warning: **implicit > declaration of function 'S2Ecst' is invalid in C99 > [-Wimplicit-function-declaration]* > > ATSINSmove(tmpret3567, PMVtmpltcstmat[0](cptr_get lexerr_loc=S2Ecst(loc_t), lexerr_node=S2Ecst(lexe

Re: where do I get atscc2js from?

2018-11-07 Thread Artyom Shalkhakov
ne. On Wednesday, November 7, 2018 at 8:51:41 AM UTC+1, Artyom Shalkhakov wrote: >> >> On Tuesday, November 6, 2018 at 6:28:46 PM UTC+2, Dmitry Kouznetsov wrote: >>> >>> So, now I have the following output: >>> >>> >> Curious. Do you have PATSHOME a

Re: Happy Holidays!

2018-12-26 Thread Artyom Shalkhakov
Hello Hongwei! On Вт, дек 25, 2018 at 6:31 , gmhwxi wrote: This mailing-list has been somewhat quiet recently. I'd like to use this occasion to wish everyone well and also to prosper in the upcoming new year! Thank you very much! I would also to congratulate you and the other members of

Re: Merging stream_vt

2019-01-01 Thread Artyom Shalkhakov
com. > To post to this group, send email to ats-lang-users@googlegroups.com. > Visit this group at https://groups.google.com/group/ats-lang-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ats-lang-users/21f9263f-e0be-4dcb-8bf6-45031eaea85a%40google

Re: Merging stream_vt

2019-01-02 Thread Artyom Shalkhakov
comp_instrset.h:327:65: > error: assignment to expression with array type > #define ATSINSstore_fltrec_ofs(tmp, tyrec, lab, val) ((tmp).lab = val) > ^ > triples_dats.c:1094:1: note: in expansion of macro ‘ATSINSstore_fltrec_ofs > ’ > ATSINSst

Re: Merging stream_vt

2019-01-02 Thread Artyom Shalkhakov
s = streamize_list_vt_elt($list_vt{int}(1, 2)) > val ys = streamize_list_vt_elt($list_vt{string}("x", "y")) > > val zs = merge (xs, ys) > > val l = stream2list_vt (zs) > val () = println!(l) // should print something like: 1,x; 2,y > > val () = li

Re: Tuple parsing bug.

2019-01-03 Thread Artyom Shalkhakov
s://groups.google.com/group/ats-lang-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ats-lang-users/d0a0a8e5-fccf-4840-af60-505e55998dcc%40googlegroups.com > <https://groups.google.com/d/msgid/ats-lang-users/d0a0a8e5-fccf-4840-af60-505e55998dcc%40googlegro

ATS3 metaprogramming and Spiral language

2019-01-08 Thread Artyom Shalkhakov
Hi all, I find this Spiral language interesting: https://github.com/mrakgr/The-Spiral-Language It's probably easy to write a program that will take ages to compile, though. I really wish ATS3 had improved on templates and on macros. :-) -- Cheers, Artyom Shalkhakov -- You received

Re: ATS2 -> ATS3 Migration Effort

2019-01-21 Thread Artyom Shalkhakov
The previous time migration was mostly painless. There were some changes for sure but most code could be translated either outright trivially, or mostly straightforwardly. Off the top of my head, most changes were: 1. different syntax for dataviewtypes and a different default when pattern-matc

Re: Stack-allocated arrays in ATS2 (or ATS3?)

2019-02-23 Thread Artyom Shalkhakov
Hi Vanessa! On Saturday, February 23, 2019 at 1:11:31 PM UTC+2, Vanessa McHale wrote: > > Is there any way to safely use alloca in ATS? I know the language has > features for both safe pointer arithmetic and safe use of > stack-allocated variables... so it would be nice to both guarantee no > ou

Re: Call-by-value assignment

2019-02-24 Thread Artyom Shalkhakov
Hi, M88 and Hongwei, On Sunday, February 24, 2019 at 5:45:34 PM UTC+2, gmhwxi wrote: > > The following line is problematic: > > prval () = $effmask_all(x := env) > > as assignment is definitely not a proof. > > I suggest that you just do > > val () = x := env > > The compiler should allocate the s

Re: Referential transparency in ATS

2019-03-21 Thread Artyom Shalkhakov
roup/ats-lang-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ats-lang-users/5eba6b86-4146-4ba2-a87f-f8c511d902f0%40googlegroups.com > <https://groups.google.com/d/msgid/ats-lang-users/5eba6b86-4146-4ba2-a87f-f8c511d902f0%40googlegroups.com?utm_medium=ema

Re: Difference between `!T` and `!T >> _`?

2019-03-21 Thread Artyom Shalkhakov
On Monday, March 18, 2019 at 7:19:46 AM UTC+2, Shimin Guo wrote: > > For !T, INT2PROGINATS says: > > Note that the symbol ! in front of the type of a function argument > indicates that the argument is call-by-value and it is preserved after a > call to the function. > > > For !T >> _, INT2PROGINA

Re: Referential transparency in ATS

2019-03-22 Thread Artyom Shalkhakov
xpression", and relates to the fact that functions in ATS can perform >>>>> side >>>>> effects without having any effect type or IO monad ascribed to the value >>>>> (again, iirc). >>>>> >>>> >>>> Well, maybe t

Re: Referential transparency in ATS

2019-03-26 Thread Artyom Shalkhakov
Hi Brandon, On Friday, March 22, 2019 at 8:49:29 PM UTC+2, Brandon Barker wrote: > > Hey Artyom, > > Thanks for the very interesting analysis and response. > > Glad you found it useful! On Fri, Mar 22, 2019 at 4:06 AM Artyom Shalkhakov > wrote: > >> Hi Brando

Re: Referential transparency in ATS

2019-03-26 Thread Artyom Shalkhakov
r to figure out the size of the variable. On Tuesday, March 26, 2019 at 10:11:11 AM UTC+2, Artyom Shalkhakov wrote: > Hi Brandon, > > On Friday, March 22, 2019 at 8:49:29 PM UTC+2, Brandon Barker wrote: >> >> Hey Artyom, >> >> Thanks for the very interesting an

Re: Referential transparency in ATS

2019-03-26 Thread Artyom Shalkhakov
function >> template). And 'a:t0ype' should be 'a:type'. >> >> fun runCommand: {a:type} Command(a) -> a >> >> Actually, I think that Command should be a linear type, which should you >> more fun! >> >> On Tue, Mar 26, 2019 at 5:49 AM A

Re: Referential transparency in ATS

2019-03-26 Thread Artyom Shalkhakov
runCommand should be implemented as a polymorphic function > (instead of a function > template). And 'a:t0ype' should be 'a:type'. > > fun runCommand: {a:type} Command(a) -> a > > Actually, I think that Command should be a linear type, which should you >

Re: Referential transparency in ATS

2019-03-26 Thread Artyom Shalkhakov
ouraged if we have 'a:type' restriction (e.g. want to return an int from an effectful function -- sure, but use heap for that...). > On Tue, Mar 26, 2019 at 9:36 AM Artyom Shalkhakov > wrote: > >> Hi Hongwei, >> >> On Tuesday, March 26, 2019 at 3:22:41 PM U

Re: Referential transparency in ATS

2019-03-26 Thread Artyom Shalkhakov
t; a?) - > Command(b)) > Did you mean to use vtype in {a,b:vtype} here? Or not? > This is a bit more involved but only an implementer like you (not user) > needs to deal with it :) > Hmmm. A sane approach to dependent types is when the user needs none of dependent types

Re: Referential transparency in ATS

2019-03-26 Thread Artyom Shalkhakov
nks! I've updated my gist with this and a note. > > > On Tue, Mar 26, 2019 at 10:14 AM Hongwei Xi > wrote: > >> >>Did you mean to use vtype in {a,b:vtype} here? Or not? >> >> Typo: vtype should be vt@ype. >> >> On Tue, Mar 26, 2019 at 10:1

  1   2   >