An open API service indexing awesome lists of open source software.

https://github.com/veeso/studying-rust

Just my path in learning the Rust language
https://github.com/veeso/studying-rust

learning learning-by-doing rust rust-lang studying

Last synced: about 1 month ago
JSON representation

Just my path in learning the Rust language

Awesome Lists containing this project

README

        

# Studying Rust

This repository is nothing special, just my little *projects* while studying the rust language.

## Table Of Contents

- [Studying Rust](#studying-rust)
- [Table Of Contents](#table-of-contents)
- [Premise](#premise)
- [Projects](#projects)
- [Hello Rust](#hello-rust)
- [Datatypes](#datatypes)
- [Control Flow](#control-flow)
- [Ownership](#ownership)
- [Structs](#structs)
- [My First Module](#my-first-module)
- [Collections](#collections)
- [Errors](#errors)
- [Generics](#generics)
- [Tests](#tests)
- [Minigrep](#minigrep)
- [FunctionalFeatures](#functionalfeatures)
- [MultiThreading](#multithreading)
- [License](#license)

## Premise

These projects are only examples I made these examples while studying Rust and even if I covered most of the language main features, they should not be taken as your rust manual, but just only a short and quick reference.
If you want to learn Rust, I suggest the official Book

## Projects

All the projects are created and managed with cargo and can be run using ```cargo run```.

### Hello Rust

Just a program which prints on stdout "Hello, Rust!".

### Datatypes

This projects introduces how variables are declared in Rust and its scalar and compound datatypes.

### Control Flow

This projects shows the control flows of Rust and how to define a function (also how to read from stdin).

### Ownership

This projects shows the ownership paradigm of Rust.

### Structs

This projects shows how Structs and Enums work in Rust.

### My First Module

An example of how to create a module in Rust, in this example I will create a utils module made up of two submodules: strutils and sysutils.
This examples shows then, how to invoke the module from the main application.

### Collections

An example which shows the most important common collection types. (Vector, String, Hash Maps)

### Errors

An example which shows how to handle errors in Rust.

### Generics

An example which shows an overview of generics, traits and lifetime

### Tests

An example which illustrates how to write tests in Rust.

### Minigrep

The same IOProject you can find at chapter 12 of the rust programming language book, but made following my ideas.

### FunctionalFeatures

A program which shows the function features (closures and iterators) of the Rust language.

### MultiThreading

Introduction to multi threading features in Rust. Does not include Mutex, because everybody knows how it works.

## License

```txt
This is free and unencumbered software released into the public domain.

Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.

In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
of the public at large and to the detriment of our heirs and
successors. We intend this dedication to be an overt act of
relinquishment in perpetuity of all present and future rights to this
software under copyright law.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.

For more information, please refer to

```