Home Man
Search
Today's Posts
Register

Post questions about C, C++, Java, SQL, and other programming languages here.

Is this a Python 3.x.x bug?

Tags
programming

Login to Reply

 
Thread Tools Search this Thread
# 8  
Old 06-08-2017
Quote:
Originally Posted by wisecracker
Hi RudiC...

So one is allowed to execute code AFTER exit has been called even if it is an ASCII string inside a variable, from awk AND Python and I thought Python was strict, what about Perl and others?
You don't "execute code AFTER exit" - you add one (or more) routines to the sequence of tasks the programme has to perform before giving control back to the caller, e.g. closing files, releasing locks, freeing allocated memory. If it is a write, you'd mayhap do it before stdout is closed, if it is just a number, you reference it just on exiting.

Quote:
Awk's exit is a statement and Python's is a function.
Both - whatever they are - start quitting the programme.

Quote:
Maybe it is just me but this should never be allowed to happen if the RC is not an integer.
Pascal wouldn't allow non-integers, C mayhap would - python might be somewhere in between.
The Following User Says Thank You to RudiC For This Useful Post:
wisecracker (06-08-2017)
# 9  
Old 06-12-2017
Quote:
Originally Posted by wisecracker
Hi Corona688...
It was this, it always needs a redirection to a file for it to work however, so nothing like the other two and technically MUCH safer:-
Huh? That program is nonsense... Safer than what? And how?
Login to Reply

« Previous Thread | Next Thread »
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
FFT for Python 2.0.x to 3.7.0. wisecracker OS X (Apple) 0 08-20-2018 09:54 AM
Python Cat infinitydon Shell Programming and Scripting 9 10-15-2014 02:36 PM
**python** unable to read the background color in python giridhar276 Shell Programming and Scripting 1 08-05-2014 02:53 AM
"ssh suse-server 'python -V' > python-version.out" not redirecting Druonysus SuSE 3 02-13-2013 08:59 PM
Help with Python. Please and thanks. o0110o Programming 2 05-28-2011 08:23 PM
AWK or python?? geparada88 Shell Programming and Scripting 5 04-06-2011 06:33 PM
Python 3.1 vs 2.6? Sterist Ubuntu 0 07-13-2010 04:48 AM
Python: bash-shell-like less functionality in the python shell Narnie Programming 0 06-25-2010 02:11 PM
what is python? kprescod4158 Shell Programming and Scripting 1 11-20-2007 07:58 PM


All times are GMT -4. The time now is 04:57 AM.

Unix & Linux Forums Content Copyrightę1993-2018. All Rights Reserved.
UNIX.COM Login
Username:
Password:  
Show Password