Welcome To Golang By Example

Menu
  • Home
  • Blog
  • Contact Us
  • Support this website
Menu

Tag: go

Runtime Error Panic in Go (Golang)

Posted on September 20, 2020September 20, 2020 by admin

Overview Runtime error in the program can happen in the below cases. All the below cases will also create a panic Out of bounds array access Calling a function on a nil…

Defer keyword in Go (Golang)

Posted on September 20, 2020November 25, 2020 by admin

This is the  chapter 14 of the golang comprehensive tutorial series. Refer to this link for other chapters of the series – Golang Comprehensive Tutorial Series Next Tutorial – PointerPrevious Tutorial – Switch Now let’s check…

Panic with Defer in Go (Golang)

Posted on September 20, 2020September 20, 2020 by admin

Overview defer function will be executed even if panic happens in a program. In fact, defer function is the only function that is called after the panic. When the panic is raised in…

Recover a panic in a different function in Go (Golang)

Posted on September 20, 2020September 20, 2020 by admin

Overview If the defer function and recover function is not called from the panicking function then it that case panic can also be recovered in the called function as well. In fact, it…

Error in Go (Golang)- Advanced

Posted on September 4, 2020November 26, 2020 by admin

This is the  chapter 27 of the golang comprehensive tutorial series. Refer to this link for other chapters of the series – Golang Comprehensive Tutorial Series Next Tutorial – Panic and RecoverPrevious Tutorial – Error –…

Error in Go (Golang)

Posted on September 4, 2020November 26, 2020 by admin

This is the  chapter 26 of the golang comprehensive tutorial series. Refer to this link for other chapters of the series – Golang Comprehensive Tutorial Series Next Tutorial – Error -Part 2Previous Tutorial – Select Statement…

Ignoring errors in Go (Golang)

Posted on September 4, 2020September 4, 2020 by admin

Overview Underscore (‘_’) operator can be used to ignore the error returned from a function call.  Before we see a program it’s important to note that error should never be ignored. It…

Wrapping and Un-wrapping of error in Go (Golang)

Posted on September 4, 2020September 4, 2020 by admin

Wrapping of error In go, error can wrap another error as well.  What does the wrapping of error mean? It means to create a hierarchy of errors in which a  particular instance…

Get underlying type from error or error assertion in Go (Golang)

Posted on September 3, 2020September 4, 2020 by admin

Overview There are two ways of getting the underlying type Using the .({type}) assert If the assert succeeds then it will return the corresponding error otherwise it will panic. Below is the…

Comparing error or error equality in Go (Golang)

Posted on September 3, 2020September 3, 2020 by admin

Overview First of all, what is meant by equality of the error?  As you already know that error is represented by the error interface in go. In go, two interfaces are equal…

Posts pagination

Previous 1 … 27 28 29 … 44 Next
Follow @golangbyexample

Popular Articles

Golang Comprehensive Tutorial Series

All Design Patterns in Go (Golang)

Slice in golang

Variables in Go (Golang) – Complete Guide

OOP: Inheritance in GOLANG complete guide

Using Context Package in GO (Golang) – Complete Guide

All data types in Golang with examples

Understanding time and date in Go (Golang) – Complete Guide

©2025 Welcome To Golang By Example | Design: Newspaperly WordPress Theme