On the device of the built-in test functionality in Rust (translation)

Hello, Habr! I present to your attention the translation of the entry "#[test]In 2018" in the blog of John Renner, which can be found here .
 
 
Recently I worked on the implementation of eRFC for custom test frameworks for Rust. Studying the code base of the compiler, I learned the inside of testing in Rust and realized that it would be interesting to share this.
 
how AST represents the identifiers . The name of each function, variable, module, etc. is stored not as a string, but rather as an ...[/test]
+ 0 -

As I am a UDP game server on Golang wrote

As I am a UDP game server on Golang wrote

Introduction


 
Recently started learning the Go programming language and for practice I decided to try writing a client-server application on it. Since I like computer games and in particular the good old "Snake" in which he played on an old black and white phone, he decided to make it her name. Yes, you heard right, it's about the game "Snake" that is divided into server and client part communicating with each other using the UPD protocol.
 
Code
 
...[/h]
+ 0 -

A boat for Starcraft on Rust

A boat for Starcraft on Rust
 
StarCraft: Brood War . How much this means to me. And for many of you. So much that I doubted whether to give a link to the wiki.
 
Once I was knocked in a personal Halt and offered to learn Rust . Like any normal people, we decided to start with
hello world
writing a dynamic library under Windows that could be loaded into the StarCraft address space and manage units.
 
The article will describe the process of finding solutions, using technologies, techniques that will allow you to learn new things in the language of Rust and its ecosystem or be inspired to implement the bot in your favorite ...
+ 0 -

Release of Rust ???

The Rust development team is pleased to announce the release of the new version of Rust: ???. Rust is a system programming language aimed at security, speed, and parallel execution of code.
 
If you have a previous version of Rust installed with rustup, then you just need to run
to update Rust to version ???.
 
$ rustup update stable
 
If you have not already installed rustup, you can set it to from the corresponding page of our website. With detailed notes to the release of Rust ??? ...
+ 0 -

"Tanks in the console" is a small announcement before the big article

Good afternoon Habr


 
 
Finally, I'm ready to continue the series of articles devoted to my project development (it is necessary to finish it up to mind), interesting plans, new projects and developments are ahead.
 
 
Missed the tanchiki, yes? Then under cat.
 
github.com/koitoTy/game_enjine
 
Tanks: github.com/koitoTy/tank_game
 
(group in can be found in the profile) Good afternoon Habr   Finally, I'm ready to continue the series of articles devoted to my project development (it is necessary to finish it up to mind), interesting plans, new projects and developments are ahead.  Missed the tanchiki, yes? Then under cat.  github.com/koitoTy/game_enjine  Tanks: github.com/koitoTy/tank_game  (group in can be found in the profile)...[/h]
+ 0 -

As the update to Rust ??? speeded up my code in more than three times

I want to share a small story about the power of LLVM and the advantages of high-level languages ​​over the assembler.
 
 
I work for Parity Technologies, which supports client Parity Ethereum . In this client, we need fast 256-bit arithmetic, which has to be emulated at the software level, because no hardware supports it hardware.
 
 
For a long time we parallelly do two implementations of arithmetic: one on Rust for stable assemblies and one with built-in assembler code (which is automatically used by the nightly version of the compiler). We do this because we store 256-bit numbers as arrays ...
+ 0 -

Operating systems from scratch; level 3 (the older half)

Operating systems from scratch; level 3 (the older half) In this part, we'll add the interrupt processing and take on the scheduler. Finally, we will have the elements of a multitasking operating system! Of course this is only the beginning of the topic. One timer interrupt, one system call, the basic part of a simple thread scheduler. Nothing complicated. However, by this we will prepare a springboard for the creation of a full-fledged system that will deal with the most real processes without any "buts." Just like in these your lines and others. Until the end of
this
course is already a little less than half.
 
Zero lab
 
The f...
+ 0 -

Operating systems from scratch; level 3 (lower half)

Operating systems from scratch; level 3 (lower half)
 
In this lab, we will implement the ability to run custom programs. Those. processes and the entire dependent infrastructure. In the beginning, we'll figure out how to switch from privileged code, how to switch process contexts. Then we implement a simple round-robin scheduler, system calls and virtual memory management. In the end, we will remove our shell from the kernel space into the user space.
 
original
 
Zero lab
 
The first lab: the younger half and ...
+ 0 -

Operating systems from scratch; level 2 (the older half)

Operating systems from scratch; level 2 (the older half) It's time to write a file system. The file system does not write itself. In this half of the lab, we still implement the FAT32 file system, attach the SD card driver to it and interact with it a little bit through our interactive shell.
 
Zero lab
 
The first lab: the younger half and the older half is
 
The younger part . Continuation under the cut.
structure FAT contains all the necessary information about the size and content of these same structures. Together with the minimum necessary description...
+ 0 -

Operating systems from scratch; level 1 (the older half)

Operating systems from scratch; level 1 (the older half) It's time for the next part. This is the second half of the translation of labs №1 . In this issue we will write peripheral drivers (timer, GPIO, UART), implement the XMODEM protocol and one utilities. Using all this we will write the shell for our kernel and the bootloader, which will allow us not to poke the microSD card back and forth.
 
The younger half .
 
Beginning reading is with zero lab .
manual for peripheral devices BCM2837 .
 
Sub phase B: System ...
+ 0 -