"use strict"

Rhodri James rhodri at kynesim.co.uk
Mon Mar 11 14:14:33 EDT 2019


On 11/03/2019 17:45, Abdur-Rahmaan Janhangeer wrote:
> Greetings,
> 
> would it be a good idea to add a use strict in py like js?
> 
> recently i was helping someone and that was one annoying part where a typo
> in a var name caused an unintended variable to slip in.
> 
> maybe something like that
> 
> # -*- strict -*-
> 
> 
> # -*- explicit -*-
> 
> could be used to prevent it

What exactly would you want "strict" (in whatever form) to do?  I'm 
guessing, but it sounds like you want more static checking.  Usually 
that's the province of linters and type annotation, depending on just 
what you want.

-- 
Rhodri James *-* Kynesim Ltd



More information about the Python-list mailing list