Get productive in Go quickly by dodging common roadblocks
About This Video
- Learn Go best practices, making it easier to get help and read others' code.
- Avoid the biggest gotchas developers from other languages run into.
- Use concurrency without losing data or crashing your program
Go is a powerful, general-purpose language that is exceptional for writing anything from servers to command-line utilities. Meant to replace languages such as Java and C++, its performance and accessibility have found an eager audience in developers from compiled and interpreted languages alike.
Much of Go's power comes from its simplicity. Although a high-level language, it doesn't have much in the way of bells and whistles. Newcomers from all languages tend to trip over the same design decisions that are less common among other languages.
In this course, you will learn to effortlessly surmount these hurdles and become more productive quickly, writing fast, stable code and, hopefully, having more fun coding than ever before!
Table of Contents
Chapter 1 : Fixing Compiler Errors
- The Course Overview 00:05:51
- Unexpected Literal, Expecting Type 00:01:05
- Unexpected Newline, Expecting Comma or } 00:01:55
- No New Variables on Left Side Of := 00:01:45
- Multiple-Value in Single-Value Context 00:01:09
- Undefined: fmt 00:00:46
- Main Redeclared in This Block 00:01:53
- Declared and Not Used 00:00:55
- Imported and Not Used 00:00:48
- Chapter 2 : Concurrency
- Chapter 3 : Dependencies
Chapter 4 : Go gotchas
- Zero Value for Non-Existent Map Keys 00:01:50
- Syntax Error: _, i := nums Used as Value 00:00:59
- Copy Argument Order Is Not Intuitive 00:01:20
- Using Break with a Select Block 00:02:26
- Using Range with a Slice Returns the Index as the First Argument 00:01:18
- Un-Exported Types Do Not Marshal to JSON 00:01:34
- The Map Type Is Not Thread Safe 00:01:27
- Unexpected Results Using Variables in Goroutine 00:01:28
Chapter 5 : Writing More Idiomatic Go
- Don’t Panic 00:02:21
- Don’t Ignore Errors 00:03:10
- Using Backticks for String Literals to Avoid Excessive Quoting 00:03:58
- Making a Map into a Set 00:02:17
- Do Not Use Mutable Global Variables 00:03:14
- Chapter 6 : Never Crash in Production!
- Chapter 7 : Interfaces in Go
- Chapter 8 : Tips on Go’s Built-in Variable Types
- Title: Troubleshooting Go Application Development
- Release date: July 2018
- Publisher(s): Packt Publishing
- ISBN: 9781788997072