Return a reference to Kernel from systemKernel()
This commit is contained in:
		
							parent
							
								
									abfcfd24cd
								
							
						
					
					
						commit
						7f72106639
					
				
					 3 changed files with 4 additions and 4 deletions
				
			
		| 
						 | 
					@ -21,10 +21,10 @@ namespace kernel {
 | 
				
			||||||
 * Static
 | 
					 * Static
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Kernel*
 | 
					Kernel&
 | 
				
			||||||
Kernel::systemKernel()
 | 
					Kernel::systemKernel()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    return &sKernel;
 | 
					    return sKernel;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/*
 | 
					/*
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -16,7 +16,7 @@ namespace kernel {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
struct Kernel
 | 
					struct Kernel
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    static Kernel* systemKernel();
 | 
					    static Kernel& systemKernel();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    void panic(const char* msg, ...);
 | 
					    void panic(const char* msg, ...);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -75,5 +75,5 @@ kmain(multiboot::Information *information)
 | 
				
			||||||
    interruptHandler.enableInterrupts();
 | 
					    interruptHandler.enableInterrupts();
 | 
				
			||||||
    console.printString("Interrupts enabled\n");
 | 
					    console.printString("Interrupts enabled\n");
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    kernel::Kernel::systemKernel()->halt();
 | 
					    kernel::Kernel::systemKernel().halt();
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue