Incremental static type analysis

12 views
Skip to first unread message

Joaquin Duo

unread,
Mar 21, 2015, 2:04:10 AM3/21/15
to shedskin...@googlegroups.com
Hi everyone:

After reading "incremental static type analysis" I tried to search the topic on the list, but did not found the phrase in another email.

Does it mean I can decorate a function/method to add hints to shedkin?

I would also love the following feature. Imagine this 2 functions

@ss.types(int, str, returns=float)
def foo( a, b):
   print('b:' + b)
   return bar(a)

@ss.types(int, returns=int)
def bar( c):
   return c*c

I would love to have type checking in an IDE like pydev. So it can warn me if "return bar(a)" does not follow annotated restrictions.
The ideal would be annotating some functions, but not all of them, so analysis is quick enough, but at the same time the programmer doesn't need to be explicit in every method/function. (so i guess the user could set some "depth" threshold before ignoring a too large problem)

Should "incremental static type analysis" make this feature easier?

About me:
I have been using shedkin for a while now. Specially for a personal project.
As a test i wanted to create a procedural engine entirely on shedkin.
https://code.google.com/p/mepinta/source/browse/#git%2Fmepinta%2Fcore%2Fpython_core%2Fmepinta%2Fpipeline%2Flo

That engine is able to call plugins in C and C++  dynamic libraries using  the "builtin" lib/ found in:
https://code.google.com/p/mepinta/source/browse/#git%2Fmepinta%2Fcore%2Fpipeline_backend%2Fpipeline_backend_c_and_cpp%2Fpipeline_backend

So the same engine can support C, C++ and Python plugins.
Kudos to shedskin developers and community!

Cheers,
Joaquín
Reply all
Reply to author
Forward
0 new messages