Common concepts when learning new programming language

gftea
1 min readMay 7, 2022

--

Learn how to learn new programming language

Type System

  • A type used to be associated with abstract representation, boundary, internal memory representation, allowed operations
  • Type extension system
  • User defined type

Scope and Lifetime

Scope is the visibility of the object, can be different from lifetime of the object.

Lifetime of an object can be in whole program but maybe only visible in a certain scope.

Control Flow

  • Conditonal
  • Loop and Iteration
  • Local jump and global jump
  • Exceptional control flow, such as exit/termination hook of program

Error Handling

  • Static error handling, e.g. error check at compilation phase
  • Error recovery
  • Error propagation
  • Stack trace

I/O Operations

Be aware of I/O bound and CPU bound operations

  • Disk I/O
  • Network I/O
  • Endianesss

Encoding and Decoding System

  • Character set
  • Character/String encoding and decoding

Memory management

Be aware of how Language handling stack and heap by default, how to manipulate it.

  • Stack
  • Heap

Module system

  • How to define a module
  • How a program is structured into module
  • Module scope and visibility

Packaging system

  • binary executable
  • library

Sync and Async

If any native async support in Language

Multi Threading

  • Thread’s local variable, atomic variable, mutex lock
  • Attach and detach threads
  • Daemonize threads

Multi Processing

  • Fork process, terminate/kill process,
  • IPC — Inter Process Communication

--

--